qlix 0.3.2__tar.gz → 0.3.4__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (113) hide show
  1. {qlix-0.3.2 → qlix-0.3.4}/BACKLOG.md +14 -16
  2. {qlix-0.3.2 → qlix-0.3.4}/CAPABILITIES.md +4 -4
  3. {qlix-0.3.2 → qlix-0.3.4}/CLI.md +2 -2
  4. {qlix-0.3.2 → qlix-0.3.4}/CUTOVER.md +11 -2
  5. {qlix-0.3.2 → qlix-0.3.4}/PKG-INFO +9 -3
  6. {qlix-0.3.2 → qlix-0.3.4}/README.md +8 -2
  7. qlix-0.3.4/examples/EXPORT-FIXTURE.md +24 -0
  8. {qlix-0.3.2 → qlix-0.3.4}/pyproject.toml +1 -1
  9. {qlix-0.3.2 → qlix-0.3.4}/scripts/check-export-fixture.py +27 -12
  10. {qlix-0.3.2 → qlix-0.3.4}/src/qlix/SKILL.md +1 -1
  11. {qlix-0.3.2 → qlix-0.3.4}/src/qlix/broker.py +1 -1
  12. {qlix-0.3.2 → qlix-0.3.4}/src/qlix/cli.py +22 -5
  13. qlix-0.3.4/src/qlix/compile_frontend.py +49 -0
  14. {qlix-0.3.2 → qlix-0.3.4}/tests/test_broker.py +3 -0
  15. {qlix-0.3.2 → qlix-0.3.4}/tests/test_dsl_cli.py +109 -0
  16. qlix-0.3.4/tests/test_export_fixture.py +87 -0
  17. {qlix-0.3.2 → qlix-0.3.4}/tests/test_frontend_runtime.py +27 -0
  18. {qlix-0.3.2 → qlix-0.3.4}/uv.lock +1 -1
  19. qlix-0.3.2/examples/EXPORT-FIXTURE.md +0 -29
  20. qlix-0.3.2/tests/test_export_fixture.py +0 -56
  21. {qlix-0.3.2 → qlix-0.3.4}/.github/workflows/ci.yml +0 -0
  22. {qlix-0.3.2 → qlix-0.3.4}/.github/workflows/publish.yml +0 -0
  23. {qlix-0.3.2 → qlix-0.3.4}/.gitignore +0 -0
  24. {qlix-0.3.2 → qlix-0.3.4}/LICENSE +0 -0
  25. {qlix-0.3.2 → qlix-0.3.4}/RELEASE.md +0 -0
  26. {qlix-0.3.2 → qlix-0.3.4}/examples/BI-AS-CODE.md +0 -0
  27. {qlix-0.3.2 → qlix-0.3.4}/examples/Qlikfile.toml +0 -0
  28. {qlix-0.3.2 → qlix-0.3.4}/examples/bi-as-code.yaml +0 -0
  29. {qlix-0.3.2 → qlix-0.3.4}/examples/policy.example.toml +0 -0
  30. {qlix-0.3.2 → qlix-0.3.4}/examples/synthetic-smoke-ui.yaml +0 -0
  31. {qlix-0.3.2 → qlix-0.3.4}/examples/synthetic-smoke.qvs +0 -0
  32. {qlix-0.3.2 → qlix-0.3.4}/examples/synthetic-smoke.yaml +0 -0
  33. {qlix-0.3.2 → qlix-0.3.4}/scripts/check-wheel-skill.sh +0 -0
  34. {qlix-0.3.2 → qlix-0.3.4}/src/qlix/__init__.py +0 -0
  35. {qlix-0.3.2 → qlix-0.3.4}/src/qlix/app_adopt.py +0 -0
  36. {qlix-0.3.2 → qlix-0.3.4}/src/qlix/app_apply.py +0 -0
  37. {qlix-0.3.2 → qlix-0.3.4}/src/qlix/app_create.py +0 -0
  38. {qlix-0.3.2 → qlix-0.3.4}/src/qlix/app_export.py +0 -0
  39. {qlix-0.3.2 → qlix-0.3.4}/src/qlix/app_frontend.py +0 -0
  40. {qlix-0.3.2 → qlix-0.3.4}/src/qlix/app_plan.py +0 -0
  41. {qlix-0.3.2 → qlix-0.3.4}/src/qlix/app_reload.py +0 -0
  42. {qlix-0.3.2 → qlix-0.3.4}/src/qlix/appcheck.py +0 -0
  43. {qlix-0.3.2 → qlix-0.3.4}/src/qlix/artifacts.py +0 -0
  44. {qlix-0.3.2 → qlix-0.3.4}/src/qlix/auth/__init__.py +0 -0
  45. {qlix-0.3.2 → qlix-0.3.4}/src/qlix/auth/browser.py +0 -0
  46. {qlix-0.3.2 → qlix-0.3.4}/src/qlix/checks.py +0 -0
  47. {qlix-0.3.2 → qlix-0.3.4}/src/qlix/direct_config.py +0 -0
  48. {qlix-0.3.2 → qlix-0.3.4}/src/qlix/dsl/__init__.py +0 -0
  49. {qlix-0.3.2 → qlix-0.3.4}/src/qlix/dsl/bookmark_audit.py +0 -0
  50. {qlix-0.3.2 → qlix-0.3.4}/src/qlix/dsl/compiler.py +0 -0
  51. {qlix-0.3.2 → qlix-0.3.4}/src/qlix/dsl/engine_validation.py +0 -0
  52. {qlix-0.3.2 → qlix-0.3.4}/src/qlix/dsl/expression_audit.py +0 -0
  53. {qlix-0.3.2 → qlix-0.3.4}/src/qlix/dsl/field_audit.py +0 -0
  54. {qlix-0.3.2 → qlix-0.3.4}/src/qlix/dsl/frontend_ui_acceptance.mjs +0 -0
  55. {qlix-0.3.2 → qlix-0.3.4}/src/qlix/dsl/planner.py +0 -0
  56. {qlix-0.3.2 → qlix-0.3.4}/src/qlix/dsl/runtime.py +0 -0
  57. {qlix-0.3.2 → qlix-0.3.4}/src/qlix/dsl/schema.py +0 -0
  58. {qlix-0.3.2 → qlix-0.3.4}/src/qlix/dsl/spec.py +0 -0
  59. {qlix-0.3.2 → qlix-0.3.4}/src/qlix/dsl/ui_acceptance.py +0 -0
  60. {qlix-0.3.2 → qlix-0.3.4}/src/qlix/dsl/ui_run.mjs +0 -0
  61. {qlix-0.3.2 → qlix-0.3.4}/src/qlix/engine/__init__.py +0 -0
  62. {qlix-0.3.2 → qlix-0.3.4}/src/qlix/engine/certificate.py +0 -0
  63. {qlix-0.3.2 → qlix-0.3.4}/src/qlix/engine/client.py +0 -0
  64. {qlix-0.3.2 → qlix-0.3.4}/src/qlix/engine/inspection.py +0 -0
  65. {qlix-0.3.2 → qlix-0.3.4}/src/qlix/engine/load_script.py +0 -0
  66. {qlix-0.3.2 → qlix-0.3.4}/src/qlix/engine/master_guard.py +0 -0
  67. {qlix-0.3.2 → qlix-0.3.4}/src/qlix/engine/qrs.py +0 -0
  68. {qlix-0.3.2 → qlix-0.3.4}/src/qlix/engine/reload.py +0 -0
  69. {qlix-0.3.2 → qlix-0.3.4}/src/qlix/engine/terminal_page.py +0 -0
  70. {qlix-0.3.2 → qlix-0.3.4}/src/qlix/exit_codes.py +0 -0
  71. {qlix-0.3.2 → qlix-0.3.4}/src/qlix/field_check.py +0 -0
  72. {qlix-0.3.2 → qlix-0.3.4}/src/qlix/frontend_apply.py +0 -0
  73. {qlix-0.3.2 → qlix-0.3.4}/src/qlix/inventory_cli.py +0 -0
  74. {qlix-0.3.2 → qlix-0.3.4}/src/qlix/manifest.py +0 -0
  75. {qlix-0.3.2 → qlix-0.3.4}/src/qlix/model.py +0 -0
  76. {qlix-0.3.2 → qlix-0.3.4}/src/qlix/policy.py +0 -0
  77. {qlix-0.3.2 → qlix-0.3.4}/src/qlix/py.typed +0 -0
  78. {qlix-0.3.2 → qlix-0.3.4}/src/qlix/script_apply.py +0 -0
  79. {qlix-0.3.2 → qlix-0.3.4}/src/qlix/script_diff.py +0 -0
  80. {qlix-0.3.2 → qlix-0.3.4}/src/qlix/script_patch.py +0 -0
  81. {qlix-0.3.2 → qlix-0.3.4}/src/qlix/script_plan.py +0 -0
  82. {qlix-0.3.2 → qlix-0.3.4}/src/qlix/signin_log.py +0 -0
  83. {qlix-0.3.2 → qlix-0.3.4}/src/qlix/stoppable.py +0 -0
  84. {qlix-0.3.2 → qlix-0.3.4}/src/qlix/ui_run.py +0 -0
  85. {qlix-0.3.2 → qlix-0.3.4}/tests/frontend_ui_acceptance.test.mjs +0 -0
  86. {qlix-0.3.2 → qlix-0.3.4}/tests/test_app_adopt.py +0 -0
  87. {qlix-0.3.2 → qlix-0.3.4}/tests/test_app_apply.py +0 -0
  88. {qlix-0.3.2 → qlix-0.3.4}/tests/test_app_check.py +0 -0
  89. {qlix-0.3.2 → qlix-0.3.4}/tests/test_app_create.py +0 -0
  90. {qlix-0.3.2 → qlix-0.3.4}/tests/test_app_name_cli.py +0 -0
  91. {qlix-0.3.2 → qlix-0.3.4}/tests/test_app_reload.py +0 -0
  92. {qlix-0.3.2 → qlix-0.3.4}/tests/test_browser_auth.py +0 -0
  93. {qlix-0.3.2 → qlix-0.3.4}/tests/test_certificate.py +0 -0
  94. {qlix-0.3.2 → qlix-0.3.4}/tests/test_direct_config.py +0 -0
  95. {qlix-0.3.2 → qlix-0.3.4}/tests/test_direct_script.py +0 -0
  96. {qlix-0.3.2 → qlix-0.3.4}/tests/test_frontend_apply_cli.py +0 -0
  97. {qlix-0.3.2 → qlix-0.3.4}/tests/test_inventory_cli.py +0 -0
  98. {qlix-0.3.2 → qlix-0.3.4}/tests/test_manifest.py +0 -0
  99. {qlix-0.3.2 → qlix-0.3.4}/tests/test_master_guard.py +0 -0
  100. {qlix-0.3.2 → qlix-0.3.4}/tests/test_model.py +0 -0
  101. {qlix-0.3.2 → qlix-0.3.4}/tests/test_persistent_reload.py +0 -0
  102. {qlix-0.3.2 → qlix-0.3.4}/tests/test_policy.py +0 -0
  103. {qlix-0.3.2 → qlix-0.3.4}/tests/test_qrs.py +0 -0
  104. {qlix-0.3.2 → qlix-0.3.4}/tests/test_script_apply.py +0 -0
  105. {qlix-0.3.2 → qlix-0.3.4}/tests/test_script_diff.py +0 -0
  106. {qlix-0.3.2 → qlix-0.3.4}/tests/test_script_patch.py +0 -0
  107. {qlix-0.3.2 → qlix-0.3.4}/tests/test_script_plan.py +0 -0
  108. {qlix-0.3.2 → qlix-0.3.4}/tests/test_session_attempts.py +0 -0
  109. {qlix-0.3.2 → qlix-0.3.4}/tests/test_session_reuse.py +0 -0
  110. {qlix-0.3.2 → qlix-0.3.4}/tests/test_signin_hygiene.py +0 -0
  111. {qlix-0.3.2 → qlix-0.3.4}/tests/test_skill.py +0 -0
  112. {qlix-0.3.2 → qlix-0.3.4}/tests/test_terminal_page.py +0 -0
  113. {qlix-0.3.2 → qlix-0.3.4}/tests/test_ui_run.py +0 -0
@@ -2,13 +2,11 @@
2
2
 
3
3
  The goal is to create or update a native Qlik app from Git-tracked **QVS load scripts and sheet YAML**, using one declarative manifest. Add a read-only way for people and agents to discover the data model and its verified business relationships. Keep deployment identities, permission grants, live snapshots, and recovery artifacts outside the authoring repo.
4
4
 
5
- ## Starting point
5
+ ## Status at qlix 0.3.3
6
6
 
7
- - **Isolated integration, not released:** blank-app creation, first reload, frontend deployment, no-op replan, and read-only export pass in one subprocess CLI test against a loopback mutual-TLS fake Engine. Live evidence remains separate for each slice.
8
- - **Released in qlix 0.2.0:** browser SSO and session hygiene, read-only direct PEM access, `--connect-ip` with TLS hostname verification, and named direct profiles. Direct app, sheet, and field reads were verified on one client-managed deployment. The published direct CLI implements reads only; this is not a property of the credential.
9
- - **Local `main`, not released:** inventory ergonomics, [CLI reference](CLI.md), Qlikfile read-only preflight and policy, and model metadata.
10
- - **Working-tree changes, not released:** separate guarded PEM script save, reload, and sheet apply. The [paired pilot](examples/BI-AS-CODE.md) was run live on one disposable app: script and frontend replay plans were no-ops, the expected fields persisted, and the KPI displayed `3` in Qlik Sense. Combined orchestration remains open.
11
- - **In Atom `main`:** generic Qlik connection and DSL imports use packaged qlix. The duplicate artifact writer and recovery journal are removed; the lock still selects qlix 0.1.0. Deployment defaults, data contracts, QVS, and domain validation stay in Atom. Remaining command wrappers are not all drop-in replacements.
7
+ - **Released on [PyPI](https://pypi.org/project/qlix/0.3.3/):** Qlikfile and trusted target policy, offline/live preflight, model metadata, guarded PEM deployment phases, app creation and first reload, read-only export and adoption, and the bundled agent guide. [CLI reference](CLI.md).
8
+ - **Verified live on disposable apps:** separate and combined PEM deployment, blank-app initialization, no-op replanning, KPI rendering, and non-empty export and adoption. These do not establish browser-SSO apply parity or coverage of published/community sheets. See [the pilot](examples/BI-AS-CODE.md) and QLX-09/10 below.
9
+ - **Atom consumer:** `main` uses published qlix 0.3.2. The QLX-11 worktree verifies 0.3.3, the offline PRI Qlikfile pilot, and removal of planning, inspection, and schema wrappers. That work is not landed. [Cutover criteria](CUTOVER.md).
12
10
 
13
11
  ## Architectural principles
14
12
 
@@ -18,16 +16,16 @@ The goal is to create or update a native Qlik app from Git-tracked **QVS load sc
18
16
  - **Explicit, resumable write phases:** Because `script save -> reload` mutates the data model before `frontend apply` can be validated, combined updates run as journaled phases (`script` -> `reload` -> `recheck & frontend`) with a post-reload checkpoint rather than one opaque apply.
19
17
  - **Locked CLI exit-code and JSON contract:** Lock one convention before new commands ship (`0` pass/no-op, `2` check failure/conflict/drift, `1` runtime/policy/usage error) so `app check`, `model`, `dsl plan`, and `qlix skill` stay consistent.
20
18
 
21
- ## Next: prove the read-only workflow
19
+ ## Read-only workflow: delivered scope
22
20
 
23
21
  | ID | Owner | Deliverable and acceptance |
24
22
  | --- | --- | --- |
25
- | QLX-01 | qlix | **Finish the CLI ergonomics slice.** Review the local changes, preserve default JSON shapes and UUID syntax, and verify exact-name selection refuses ambiguous matches. Check `--help` and examples from an installed wheel. Commit, push, and release only with approval. |
23
+ | QLX-01 | qlix | **CLI ergonomics.** Preserve default JSON shapes and UUID syntax, and refuse ambiguous exact-name selection. Check `--help` and examples from an installed wheel. |
26
24
  | QLX-03 | qlix | **Bind connection policy per app target (build with QLX-02).** Implement the unified `target -> policy -> transport` resolver. The tracked file requests a connection name; trusted local or CI config resolves the connection type, endpoint, app UUID scope, and allowed operations. First support read-only preflight with certificate or SSO. Deny missing/unknown policy, unsupported transport capabilities, and target mismatches before connecting. A checkout cannot grant itself access. This policy restricts `qlix`, not the privileges of the underlying credential. |
27
25
  | QLX-02 | qlix | **Add `Qlikfile.toml`, unified exit codes, and `qlix app check` (build with QLX-03).** Version the manifest; reference a tracked `.qvs` file and sheet YAML. Offline checks require no local credentials. A target check resolves through QLX-03, validates chart structure and supported live-apply features, and checks fields, variables, bookmarks, and expressions where supported. Report `passed`, `failed`, and `not_verified` separately. Compare the tracked QVS digest to the live script so missing fields/expressions caused by an un-reloaded QVS change are explicitly flagged as `not_verified` (pending reload) rather than hard failures on an unchanged script. Lock the exit-code contract (`0` pass, `2` check failure/drift, `1` runtime/policy error). Do not claim syntax, reload, or render acceptance from offline checks. The command cannot persist changes. |
28
26
  | QLX-04 | qlix | **Expose the observed app model (parallel Phase 1 track).** Add a metadata-only `qlix model` view that preserves table membership and the associations Qlik reports, instead of flattening to field names. Include app identity, visibility/scope, and explicit unknowns. Keep identifiers stable within the snapshot, avoid sampling rows, and do not infer keys or data types the Engine has not established. |
29
27
  | QLX-05 | Atom | **Explain verified data relationships (parallel Atom track).** Compose existing Atom registry, semantic views, and join catalog with the observed model from QLX-04. Pilot one explicit `(app UUID, model table) → dataset` mapping. Return grain, verified keys, direction/cardinality, required filters, provenance, and sensitivity where known. Distinguish observed associations from verified joins; no verified path means no recommendation. Do not duplicate the registry or expose row values. |
30
- | QLX-06 | qlix | **Bundle a version-matched agent guide (end of Phase 1).** Ship a small `SKILL.md` as package data, exposed by `qlix skill` (implemented, not released), *after* QLX-01–04 settle so it documents the real manifest, `app check`, `model`, and exit codes on the first pass. Cover connection choice, stable JSON/exit contracts, session reuse, secret handling, and write approval. Do not auto-register it in a harness. Verify it from an installed wheel, offline, without configuration. |
28
+ | QLX-06 | qlix | **Bundle a version-matched agent guide.** Released as package data, exposed by `qlix skill`, and verified offline from an installed wheel without configuration. Cover connection choice, stable JSON/exit contracts, session reuse, secret handling, and write approval. Do not auto-register it in a harness. |
31
29
 
32
30
  ### QLX-05 pilot: lineage is not join equivalence
33
31
 
@@ -48,23 +46,23 @@ unmapped join key must produce **no app-level join recommendation**. Test both a
48
46
  synthetic key-preserving mapping and a grouped-source negative case like the one
49
47
  above. Any recommendation must retain the Atom catalog's caveat and provenance.
50
48
 
51
- ## Then: guarded create and update
49
+ ## Guarded create and update: scope and evidence
52
50
 
53
- For headless deployment, first connect PEM to the existing guarded script and frontend workflows without duplicating apply logic or granting writes by default. The explicit approval and live pilot for those separate PEM paths are complete on a disposable app. Use the observed behavior when designing combined orchestration in QLX-07. Browser SSO can be used to verify rendering; it is not a deployment prerequisite. QLX-08 repeats the pilot through the combined workflow.
51
+ Headless deployment reuses the guarded script and frontend workflows without granting writes by default. The separately approved PEM pilot exercised both the individual commands and the combined manifest workflow on disposable apps. Browser SSO can verify rendering; it is not a PEM deployment prerequisite.
54
52
 
55
53
  | ID | Owner | Deliverable and acceptance |
56
54
  | --- | --- | --- |
57
55
  | QLX-07 | qlix | **Plan and apply an update to an existing app.** Read-only `app plan` now combines script and frontend review, deferring sheet review when the script changes. `app apply` executes one explicitly approved phase at a time and resumes only from verified checkpoints; the combined PEM pilot verified all three phases and a no-op replan. The renamed synthetic sheet was also checked in the browser: at a 768 × 540 CSS viewport the chart body had a visible standalone KPI value of `3`, separate from the chart title. This verifies the existing-app pilot, not newly created apps. Combine the existing script and frontend workflows without bypassing their guards, modeled as explicit, journaled resumable phases (`script` → `reload` → `recheck & frontend`) with a post-reload checkpoint. Bind the reviewed plan to endpoint, app UUID, source digests, and observed state. Separate script save, authorized reload, and sheet apply. After reload, recheck fields and reject changes outside the reviewed plan; request a fresh review when the resulting model invalidates the plan. Preserve unmanaged objects and report drift. Journal each phase, including partial or unknown outcomes; do not retry an uncertain write automatically or imply rollback. A verified rerun issues no save or reload. |
58
- | QLX-08 | qlix | **Prove the paired pilot on a disposable app.** With explicit authorization for that target and those actions, run QLX-07 end to end: validate and save the tracked QVS, reload, verify the expected field inventory, apply the reviewed sheet spec, and verify the KPI renders 3. Reinspect and show a no-op plan. Exercise drift refusal, preservation of unmanaged sheets, and recovery reporting (use a fake Engine for injected failures unless separately approved). No production app or data dependency. |
59
- | QLX-09 | qlix | **Create and initialize an app explicitly.** First slice: `app create` records the UUID from a one-shot blank-app creation; not live-tested. Receipt-bound first reload is implemented with a separate UUID-scoped update grant; a subprocess CLI test over loopback mutual TLS proves create → script → first reload → frontend → no-op replan against a fake Engine. Live acceptance passed on 2026-12-04 in a personal workspace app (`cbc3742f-…`): create → script save → receipt-bound first reload → sheet apply (3 creations) → no-op replan → read-only export; Qlik Sense rendered the KPI as 3. Live finding: a never-reloaded app omits `qHasData`/`qIsOpenedWithoutData` from its layout, so the blank check now requires an empty `GetTablesAndKeys` inventory instead of explicit `false` flags. Require its own capability and approval; record the new UUID before initialization. A create-only grant can initialize only that new UUID, not update an existing app by name. Detect and report an uncertain creation result rather than creating a second app. No deletion or publication in this slice. Depends on QLX-03 and the guarded execution contract in QLX-07. |
56
+ | QLX-08 | qlix | **Paired pilot on a disposable app.** The live PEM workflows verified saved QVS, reload, field inventory, sheet apply, no-op replanning and a rendered KPI of 3. Drift refusal, unmanaged-object preservation and injected recovery failures are covered by fake Engine tests; do not infer live failure-injection or browser-SSO apply coverage. No production app or data dependency. |
57
+ | QLX-09 | qlix | **Create and initialize an app explicitly.** `app create` records the UUID from a one-shot blank-app creation. Receipt-bound first reload is implemented with a separate UUID-scoped update grant; a subprocess CLI test over loopback mutual TLS proves create → script → first reload → frontend → no-op replan against a fake Engine. Live acceptance passed on 2026-12-04 in a personal workspace app (`cbc3742f-…`): create → script save → receipt-bound first reload → sheet apply (3 creations) → no-op replan → read-only export; Qlik Sense rendered the KPI as 3. Live finding: a never-reloaded app omits `qHasData`/`qIsOpenedWithoutData` from its layout, so the blank check now requires an empty `GetTablesAndKeys` inventory instead of explicit `false` flags. Require its own capability and approval; record the new UUID before initialization. A create-only grant can initialize only that new UUID, not update an existing app by name. Detect and report an uncertain creation result rather than creating a second app. No deletion or publication in this slice. Depends on QLX-03 and the guarded execution contract in QLX-07. |
60
58
 
61
59
  The permission model for QLX-07 onward should distinguish read, create/initialize, script save, reload, and frontend update. Enforce it at execution as well as planning. An absent app, typo, authorization failure, or drift is not permission to create or delete anything. Test the same policy decisions for PEM and SSO, including read-only and app-scoped write grants. Test adapter support separately; an allowed but unimplemented operation must fail before attempting a write.
62
60
 
63
- ## Later: adopt existing apps and finish the consumer cutover
61
+ ## Remaining acceptance: published visibility and consumer cutover
64
62
 
65
63
  | ID | Owner | Deliverable and acceptance |
66
64
  | --- | --- | --- |
67
65
  | QLX-10 | qlix | **Export before adoption.** First slice: `qlix app export` captures the visible frontend through a policy-bound PEM target, with opt-in variable definitions and bookmark IDs/titles, excluding saved bookmark selections. Default and opt-in exports passed a live read-only PEM smoke on a disposable app (one sheet, one master item, two fields, no variables or bookmarks reported). Live non-empty check passed on the 2026-12-04 acceptance app (one script-created variable, one bookmark; no selection state exported); live Qlik requires `qType: "variable"` in `GetVariables`, which the first slice omitted. `qlix app adopt` (read-only) now writes an ownership baseline only when every declared object already matches; verified live: matching spec adopted to the same baseline as the deploy, an edited spec was refused, and the adopted baseline turned conflicts into reviewed updates. Still to do: check known published/community sheets using the [acceptance fixture](examples/EXPORT-FIXTURE.md). A passing fixture does not establish global coverage. Record visibility and omissions, including whether base/published and community visibility can be verified. No data rows. Do not claim a complete backup or lossless YAML conversion. Keep ownership adoption separate: establish the mapping and review it before an existing object can be changed. |
68
- | QLX-11 | Atom | **Finish wrapper migration.** Bring the offline compile/schema runbook change through Atom's gate. Keep wrappers with distinct outputs or safety behavior until callers migrate. In particular, Atom's planner exits 2 on conflicts while the pinned qlix plan can exit 0 with JSON `status: conflicts`; inspection formats and apply recovery also need parity review. Upgrade the Atom lock from an approved published artifact only after consumer checks; never lock to a developer checkout or machine-local profile. |
66
+ | QLX-11 | Atom | **Finish wrapper migration.** Published qlix 0.3.3 returns exit 2 with JSON for conflicting `dsl plan` results and adds private `state.json` to broker inspection. Atom's unmerged worktree pins the published artifact, retires diff, inspect and schema wrappers, and passes the data-free gate. Keep the compile wrapper for its summary and source-safe file output. Keep the live apply wrapper until the separately authorized browser-SSO rehearsal demonstrates reviewed apply, private recovery artifacts, a no-op replan and stale-plan refusal. Do not lock to a developer checkout or machine-local profile. |
69
67
 
70
- **Not in scope for the first release:** a catalog service, continuous reconciliation, arbitrary JSON-to-DSL conversion, app deletion, automatic publication, or automatic rollback. Start with **QLX-03 + QLX-02** (policy resolver, manifest, unified exit codes, and read-only preflight) in parallel with **QLX-04** (`qlix model` metadata discovery); ship **QLX-06** (`qlix skill`) once those settle, and prove the guarded PEM path on a disposable app before finalizing **QLX-07**.
68
+ **Not in scope for the first release:** a catalog service, continuous reconciliation, arbitrary JSON-to-DSL conversion, app deletion, automatic publication, or automatic rollback.
@@ -5,15 +5,15 @@
5
5
  | Capability and local source | `qlix` status | Upstream reference and parity check |
6
6
  | --- | --- | --- |
7
7
  | Shared named browser SSO and app selection — Dotfiles `bin/qlik` | **Ported.** `connect`, `connections`, `use`, `disconnect`; one per-user broker connection, serialized commands, idle teardown. | [CLI contexts](https://qlik.dev/toolkits/qlik-cli/qlik-cli-contexts/) document JWT for client-managed contexts; [Windows context login](https://qlik.dev/toolkits/qlik-cli/context/context-login/) documents username/password. No tested replacement for this deployment's interactive Microsoft/SAML session. A remembered app is not an open Engine document. |
8
- | Engine sessions and app handles — Atom `qlik_engine.py`, `_browser_auth.py`; Dotfiles broker | **Ported.** Python transport and client; The broker reuses one same-app Engine connection and handle across serialized reads; handles are not exposed to CLI callers. A separate `qlix direct` path reads apps, sheets, and fields over mutual TLS with an exported PEM client certificate; it is read-only, does not use the broker, and was verified only against a local test Engine. | [QIX API](https://qlik.dev/apis/json-rpc/qix/) and [`@qlik/api/qix`](https://qlik.dev/toolkits/qlik-api/qix/) distinguish app sessions, identity/selection state, and resume/reconnect. This port does not promise SDK-style resumption, Cloud auth, PFX or encrypted-key loading, or certificate-backed writes. [`enigma.js`](https://github.com/qlik-oss/enigma.js) and [`enigma-go`](https://github.com/qlik-oss/enigma-go) are Engine clients, not browser SSO brokers. |
9
- | App, sheet, field, object, and master inspection — Atom `list_apps.py`, `inspect_app.py`, `inspect_frontend.py`, `snapshot_master_library.py`; Dotfiles metadata commands | **Ported with interface changes.** `apps`, `sheets`, `fields`, `inspect`, `masters`; explicit QRS opt-in, dual-plane QIX/QRS master check. Old CSV output and legacy snapshot variants are not drop-in compatible. **New:** `model` reports table membership and Engine-reported associations from three metadata methods only, with no row data; unit and fake-Engine tested, not yet run live. | [QRS client-managed guide](https://qlik.dev/toolkits/qlik-cli/qlik-cli-qrs-get-started/) and [SDK QIX app sessions and list APIs](https://qlik.dev/toolkits/qlik-api/qix/). QRS visibility is not an attestation of completeness; require matching Engine inventory. |
8
+ | Engine sessions and app handles — Atom `qlik_engine.py`, `_browser_auth.py`; Dotfiles broker | **Ported.** Python transport and client. The broker reuses one same-app Engine connection and handle across serialized reads; handles are not exposed to CLI callers. A separate `qlix direct` path reads apps, sheets, and fields over mutual TLS with an exported PEM client certificate; it is read-only, does not use the broker, and has been verified on one client-managed deployment. | [QIX API](https://qlik.dev/apis/json-rpc/qix/) and [`@qlik/api/qix`](https://qlik.dev/toolkits/qlik-api/qix/) distinguish app sessions, identity/selection state, and resume/reconnect. This port does not promise SDK-style resumption, Cloud auth, PFX or encrypted-key loading, or generic certificate-backed writes through `qlix direct`. Policy-bound PEM writes are separate `app` commands. [`enigma.js`](https://github.com/qlik-oss/enigma.js) and [`enigma-go`](https://github.com/qlik-oss/enigma-go) are Engine clients, not browser SSO brokers. |
9
+ | App, sheet, field, object, and master inspection — Atom `list_apps.py`, `inspect_app.py`, `inspect_frontend.py`, `snapshot_master_library.py`; Dotfiles metadata commands | **Ported with interface changes.** `apps`, `sheets`, `fields`, `inspect`, `masters`; explicit QRS opt-in, dual-plane QIX/QRS master check. Old CSV output and legacy snapshot variants are not drop-in compatible. `model` reports table membership and Engine-reported associations from three metadata methods only, with no row data; a live smoke observed the synthetic acceptance model. | [QRS client-managed guide](https://qlik.dev/toolkits/qlik-cli/qlik-cli-qrs-get-started/) and [SDK QIX app sessions and list APIs](https://qlik.dev/toolkits/qlik-api/qix/). QRS visibility is not an attestation of completeness; require matching Engine inventory. |
10
10
  | Load-script read/syntax — Atom `reload_*.py`, `check_pri_script_syntax.py`, `check_tc_staging_script.py`, and syntax-check wrappers | **Ported for syntax and hashes.** `script-hash` and `script check`; anchor app can route the WebSocket without `OpenDoc`, and optional zero-valued parser variables exist only in the transient app. Raw diagnostics and script export are not CLI parity. | [Official `app validatescript`](https://qlik.dev/toolkits/qlik-cli/app/app-validatescript/) is the reference for script validation. The transient workflow uses `CreateSessionApp`, `CreateVariableEx`, `SetScript`, `CheckScriptSyntax`; no reload or save. A successful syntax check does not validate source data. |
11
11
  | Script preview, preparation, deployment, reload, progress, cancellation — Atom `prepare_comop_m2_script.py`, `reload_pri_*`, `reload_vehicle_evolution.py`, `comop_reload_progress.py` | **Partial.** Offline candidate preparation via `script patch`, private local diff via `script diff`, read-only hash comparison via `script plan`, guarded script-only save/readback via `script apply`, and a monitored transient reload helper are ported. The Python-only persistent reload primitive configures full reload and checks terminal progress without saving, cancelling or retrying. Live verification and consumer integration remain. Keep target mapping, producer/consumer order, QVD readiness and domain-specific failure policy in Atom. | [Official `app build`](https://qlik.dev/toolkits/qlik-cli/app/app-build/) updates, reloads and saves by default, with `--no-reload` and `--no-save`. Do not replace Atom’s exact hash checks, private backups, domain readiness probes or save-after-verification rules with that default. [DoReloadEx](https://help.qlik.com/en-US/sense-developer/May2026/Subsystems/EngineJSONAPI/Content/service-doc-doreloadex.htm) may report success when indexing fails, and [GetProgress(0)](https://help.qlik.com/en-US/sense-developer/May2026/Subsystems/EngineJSONAPI/Content/service-global-getprogress.htm) returns reduced information. The helper treats missing terminal evidence as uncertain. |
12
12
  | Declarative UI compiler, schemas, dependency audits, reviewed apply — Atom `libs/core/qlik_frontend`, `compile_*`, `diff_frontend`, `validate_frontend_*`, `apply_frontend` | **Ported.** `dsl` commands and Python APIs. Apply uses a separate session, requires explicit target and reviewed plan, journals before writes and has no automatic rollback. | [QIX](https://qlik.dev/apis/json-rpc/qix/) provides the actual properties and object APIs. [Official `app build`](https://qlik.dev/toolkits/qlik-cli/app/app-build/) accepts generic object JSON; it is not Atom’s YAML compiler or ownership-aware planner. Engine round-trip and actual rendering remain distinct checks. |
13
13
  | One-off app repair guards — Atom `change_template.py`, `live_master_guard.py`, `dedupe_masters.py` and repair scripts | **Partial.** Snapshot/patch helpers and reusable measure/dimension drift guards are in the package. Generic orphan/inbound-reference checks still need an explicit safe deletion workflow if retained. App-specific patches, branding and destructive target lists stay in Atom. | Use QIX object/master properties and reference inventory for verification. A successful `Destroy*` call is not a proof of zero inbound references. |
14
14
  | Browser UI acceptance — Atom `compile_frontend_ui_acceptance.py`, `frontend_ui_acceptance.mjs` | **Partial.** `dsl ui-schema`, `dsl ui-manifest`, and `dsl ui-run` expose the compiler and packaged runner. A trusted local driver supplies the authenticated tab; actual browser handoff and a live smoke remain. | QIX layout data is not a browser assertion. Keep this layer separate from Engine inspection. |
15
-
16
- | Tracked targets, trusted policy, and read-only preflight — new `qlix` slice | **Implemented and unit/fake-Engine tested.** A versioned `Qlikfile.toml` names a logical connection plus tracked QVS and sheet YAML. Trusted local or CI policy resolves transport (SSO broker or direct PEM), endpoint, app UUID scope, and capabilities; policies inside the manifest directory or its Git worktree are refused. `qlix app check` validates offline without credentials and adds a live preflight with `--target`, reporting `passed`, `failed`, and `not_verified` separately with locked exit codes (0 pass, 2 failure/drift, 1 runtime/policy/usage). | The Engine preflight reads the stored script and metadata only: `GetScript`, field/variable/bookmark existence, and `CheckExpression`. It does not save, reload, or render, and a matching stored-script digest is not treated as proof of reload. Live SSO and certificate transports are covered by fake tests; no live deployment was exercised for this slice. |
15
+ | Tracked targets, trusted policy, and read-only preflight | **Released and unit/fake-Engine tested.** A versioned `Qlikfile.toml` names a logical connection plus tracked QVS and sheet YAML. Trusted local or CI policy resolves transport (SSO broker or direct PEM), endpoint, app UUID scope, and capabilities; policies inside the manifest directory or its Git worktree are refused. `qlix app check` validates offline without credentials and adds a live preflight with `--target`, reporting `passed`, `failed`, and `not_verified` separately with locked exit codes (0 pass, 2 failure/drift, 1 runtime/policy/usage). | The Engine preflight reads the stored script and metadata only: `GetScript`, field/variable/bookmark existence, and `CheckExpression`. It does not save, reload, or render, and a matching stored-script digest is not treated as proof of reload. Both preflight transports have fake-Engine coverage. Live PEM deployment was verified separately on disposable apps; that does not verify live browser-SSO preflight. |
16
+ | Manifest deployment and adoption | **Released.** Policy-bound PEM `app create`, phased `app plan`/`app apply`, read-only export and adoption. Disposable-app evidence and remaining visibility checks are recorded in [the backlog](BACKLOG.md). | The manifest grants no permissions. Read-only export is visibility-scoped, not a backup or a lossless conversion. |
17
17
 
18
18
  ## Reference boundaries
19
19
 
@@ -37,7 +37,7 @@ qlix direct --profile work fields "$APP_ID"
37
37
  | `app plan [QLIKFILE] --target NAME --output FILE` | Read-only summary and private combined app review. Exit **2** when blocked; otherwise inspect the phase statuses. |
38
38
  | `app apply [QLIKFILE] --target NAME --phase PHASE` | Execute one [separately approved phase](README.md#apply-a-combined-plan-one-phase-at-a-time), with an exact review hash and private run directory. |
39
39
  | `inspect` (SSO only) | JSON summary pointing to a new directory containing `app.json` and `library.json` |
40
- | `dsl compile` | Compiled JSON; silent on successful `--check` |
40
+ | `dsl compile` | Compiled JSON by default; `--check` is silent. Since 0.3.4, `--summary` prints a validated inventory and `--output` writes JSON to a new private file. |
41
41
  | `dsl plan` / `dsl apply` without `--apply` | JSON plan |
42
42
  | Successful live `dsl apply` | A text summary with the recovery directory, not JSON |
43
43
 
@@ -109,6 +109,6 @@ normal fresh frontend plan; do not reuse the first-reload plan.
109
109
 
110
110
  - Invalid command syntax normally exits **2**. Handled config or connection failures normally exit **1** and report to stderr.
111
111
  - `app check` reserves **2** for a definite check failure or drift and uses **1** for runtime, policy, or usage errors. **0** means no definite failure, not that every check passed: always inspect `status` and `not_verified`.
112
- - `dsl plan` can exit **0** with `"status": "conflicts"`. Require `status == "reviewable"` in the JSON before considering apply. `dsl apply` in preview mode exits **2** for a matching but conflicting plan and **1** for a handled failure such as a changed reviewed plan.
112
+ - `dsl plan` prints the plan and exits **2** when its JSON `status` is `"conflicts"`, **0** when it is `"reviewable"`. Still require `status == "reviewable"` before considering apply. `dsl apply` in preview mode exits **2** for a matching but conflicting plan and **1** for a handled failure such as a changed reviewed plan.
113
113
  - `dsl validate-fields`, `dsl validate-expressions`, and `script check` can print a JSON report and still exit **1** when validation fails. `dsl ui-run` exits **1** for a failing report.
114
114
  - A lost reply from a write is not a rollback. Inspect recovery artifacts and live state before retrying. Do not retry session-limit refusals in a loop.
@@ -2,6 +2,15 @@
2
2
 
3
3
  `qlix` owns generic connection, QIX/QRS and frontend delivery code. Atom owns deployment defaults and business behavior. Dotfiles owns installation, operator defaults and Rex wiring. Do not retain local import shims or vendor the package in either repository.
4
4
 
5
+ ## Current Atom state
6
+
7
+ Atom `main` resolves published qlix 0.3.2. The unmerged QLX-11 worktree
8
+ resolves 0.3.3, uses the packaged planning, inspection and schema commands,
9
+ and checks the PRI consumer script and sheet spec together through an offline
10
+ Qlikfile. The data-free gate passed; no Qlik deployment was performed for this
11
+ cutover. The compiler's file output and validated inventory, and the live
12
+ apply wrapper, remain in Atom.
13
+
5
14
  ## Cutover criteria
6
15
 
7
16
  The goal is a working replacement for each workflow the consumers still need, not a PyPI release or matching command names. A locally built wheel is sufficient for rehearsal. Before a shared checkout depends on the package, pin an artifact its consumers can install reproducibly; do not put a developer's checkout or home-directory path in the shared lockfile.
@@ -11,7 +20,7 @@ The goal is a working replacement for each workflow the consumers still need, no
11
20
  | Dotfiles browser sign-in, reuse, and app/sheet metadata | Live two-terminal Rex smoke passed; idle/disconnect/error handling covered by subprocess tests. | Done for the local cutover; legacy broker and duplicate tests removed. |
12
21
  | Atom frontend compiler, plan, and bundle provenance | Offline compiler, planner, and Qlik regression suites passed using the wheel in a disposable Atom checkout. | Keep domain artifacts in Atom and rerun after switching the pinned dependency. |
13
22
  | Atom inventory, master snapshots, and syntax validation | Live QIX sheet/field commands and a complete private snapshot reused one socket (53 sheets, 261 fields, 140 reported masters). A seeded transient syntax check passed with zero errors and its second socket was not retained. Fake QRS contract tests pass. | Verify QRS on an authorized deployment if needed by consumers, and check legacy file formats before deleting wrappers. |
14
- | Atom frontend writes and recovery | Fake Engine tests exercise drift rejection, journal-before-write, save, and verification. | With separate authorization, test on a disposable app: reviewed apply, reinspection/no-op, and drift rejection before writes. |
23
+ | Atom frontend writes and recovery | Policy-bound PEM apply was exercised live; fake Engine tests cover the browser-broker path, drift rejection, and journal-before-write. | With separate authorization, exercise installed `qlix dsl apply` through browser SSO on a disposable app: verify persistence and private recovery artifacts, replan to no-op, refuse a stale plan before writes, and restore the fixture. PEM evidence does not close this gate. |
15
24
  | Atom script deployment/reload | Local diff, hash-bound plan, guarded script-only save, and a caller-owned persistent reload helper are implemented. The helper monitors but does not save, retry, or cancel persistent work. | On an authorized disposable app, prove script save and that the deployment reports terminal progress through `GetProgress(0)`. Integrate the helper without changing Atom’s readiness checks, recovery policy or save ordering. |
16
25
  | Atom browser acceptance | The installed CLI can export the suite schema, compile a manifest, and invoke the packaged runner through a trusted driver module. | Smoke-test a real driver on a disposable app; keep any Atom suites and fixtures that assert business behavior. |
17
26
 
@@ -38,7 +47,7 @@ Do not remove the remaining Atom implementation merely because a wheel builds or
38
47
 
39
48
  ## Dotfiles live smoke and retirement
40
49
 
41
- The installed `0.1.0` wheel completed interactive browser SSO on WSLg from Rex. A second Rex terminal reused the same named broker to list apps and read sheet metadata. No apps were changed. Dotfiles then removed its broker and duplicate lifecycle tests; its Justfile accepts an approved wheel and verifies the supplied release SHA-256 before handing it to `uv`. The old implementing files' uncommitted changes were backed up privately before removal. The Atom import switch remains a rehearsal, not a production dependency change. A later parity run reached the Hub but the Engine socket closed with code 1001 (reported as a likely session limit). The transient syntax check did not run and private snapshot capture was not reached. No automatic retry or persistent app change occurred.
50
+ The installed `0.1.0` wheel completed interactive browser SSO on WSLg from Rex. A second Rex terminal reused the same named broker to list apps and read sheet metadata. No apps were changed. Dotfiles then removed its broker and duplicate lifecycle tests; its Justfile accepts an approved wheel and verifies the supplied release SHA-256 before handing it to `uv`. The old implementing files' uncommitted changes were backed up privately before removal. At the time of this smoke, the Atom import switch was still only a rehearsal. A later parity run reached the Hub but the Engine socket closed with code 1001 (reported as a likely session limit). The transient syntax check did not run and private snapshot capture was not reached. No automatic retry or persistent app change occurred.
42
51
 
43
52
  The updated broker subsequently passed the socket reuse and snapshot smoke in Rex: from zero Engine sockets, three metadata commands and a full private snapshot reached one successful open, with the same broker PID. The snapshot was mode `0600`; it was removed after counting metadata. A synthetic transient syntax check with a seeded variable increased the count to two, confirmed success, and left no cached Engine socket. There was no persistent save, reload, or app modification.
44
53
 
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.5
2
2
  Name: qlix
3
- Version: 0.3.2
3
+ Version: 0.3.4
4
4
  Summary: CLI-centric Qlik Sense Engine API client, script manager, and declarative frontend DSL
5
5
  Project-URL: Homepage, https://github.com/huaxel/qlix
6
6
  Project-URL: Repository, https://github.com/huaxel/qlix
@@ -172,7 +172,7 @@ Keep the export out of Git and store the private key in a private directory on t
172
172
 
173
173
  ## Inspect apps without writes
174
174
 
175
- - `inspect` captures app structure and master definitions, not data pages, in a new private directory. Treat definitions, field names, and embedded literals as sensitive.
175
+ - `inspect` captures app structure and master definitions, not data pages, in a new private directory: `app.json` (sheet snapshot), `library.json` (masters), and `state.json` (full generic-object inventory for repair tools). Treat definitions, field names, and embedded literals as sensitive.
176
176
  - `script-hash` returns a SHA-256 digest, not live script contents.
177
177
  - `qlix script check candidate.qvs` uses a transient Engine app; it does not reload, save, or open a persistent app. Use `--anchor-app UUID` if the proxy needs an app route and repeat `--seed-zero NAME` for parser defaults that a reload would otherwise assign. It reports a digest and error count, not raw Engine diagnostics.
178
178
  - Broker requests are capped at 4 MiB including JSON encoding. The broker does not expose arbitrary RPC or export rows.
@@ -233,7 +233,13 @@ qlix dsl apply spec.yaml --app "$APP_ID" --snapshot inspection/app.json \
233
233
  --library inspection/library.json --review-plan review.json
234
234
  ```
235
235
 
236
- Compilation, field auditing, UI manifest generation, planning, and apply preview are offline. A successful `dsl plan` invocation can still return `"status": "conflicts"`; scripts must check that the JSON status is `reviewable` before passing the plan to apply. `validate-expressions` uses the named broker for metadata-only checks of expressions, fields, variables, and bookmarks. Use `qlix dsl ui-schema` to export the acceptance suite schema. To run a compiled manifest, use `qlix dsl ui-run manifest.json --driver /path/to/trusted-driver.mjs --output report.json` (requires Node.js).
236
+ Since 0.3.4, `dsl compile --summary` prints a validated
237
+ sheet and object inventory and `--output PATH` writes JSON to a new private
238
+ file. The parent directory must exist. Existing paths, including source aliases,
239
+ are refused. These flags can be combined; use `--indent N` to change JSON
240
+ indentation. `--check` cannot be combined with `--summary` or `--output`.
241
+
242
+ Compilation, field auditing, UI manifest generation, planning, and apply preview are offline. `dsl plan` exits 2 when the plan has conflicts (the JSON is still printed); scripts should also check that the JSON status is `reviewable` before passing the plan to apply. `validate-expressions` uses the named broker for metadata-only checks of expressions, fields, variables, and bookmarks. Use `qlix dsl ui-schema` to export the acceptance suite schema. To run a compiled manifest, use `qlix dsl ui-run manifest.json --driver /path/to/trusted-driver.mjs --output report.json` (requires Node.js).
237
243
 
238
244
  The driver is executable local code, not a downloaded manifest dependency. It exports `async withTab({baseUrl, appId}, run)`, supplies an authenticated tab on the intended disposable app's sheet, awaits `run(tab)` once, and owns cleanup. The tab must expose `playwright`, `goto`, `reload`, `getAXState`, and `dev.logs` as used by the packaged runner. Keep driver stdout clear. The CLI writes a new private report and exits nonzero on assertion failure. It does not open a browser, start SSO, or manage Qlik slots on the driver's behalf; use a driver that reuses the authorized browser session. This integration is tested offline, not live.
239
245
 
@@ -147,7 +147,7 @@ Keep the export out of Git and store the private key in a private directory on t
147
147
 
148
148
  ## Inspect apps without writes
149
149
 
150
- - `inspect` captures app structure and master definitions, not data pages, in a new private directory. Treat definitions, field names, and embedded literals as sensitive.
150
+ - `inspect` captures app structure and master definitions, not data pages, in a new private directory: `app.json` (sheet snapshot), `library.json` (masters), and `state.json` (full generic-object inventory for repair tools). Treat definitions, field names, and embedded literals as sensitive.
151
151
  - `script-hash` returns a SHA-256 digest, not live script contents.
152
152
  - `qlix script check candidate.qvs` uses a transient Engine app; it does not reload, save, or open a persistent app. Use `--anchor-app UUID` if the proxy needs an app route and repeat `--seed-zero NAME` for parser defaults that a reload would otherwise assign. It reports a digest and error count, not raw Engine diagnostics.
153
153
  - Broker requests are capped at 4 MiB including JSON encoding. The broker does not expose arbitrary RPC or export rows.
@@ -208,7 +208,13 @@ qlix dsl apply spec.yaml --app "$APP_ID" --snapshot inspection/app.json \
208
208
  --library inspection/library.json --review-plan review.json
209
209
  ```
210
210
 
211
- Compilation, field auditing, UI manifest generation, planning, and apply preview are offline. A successful `dsl plan` invocation can still return `"status": "conflicts"`; scripts must check that the JSON status is `reviewable` before passing the plan to apply. `validate-expressions` uses the named broker for metadata-only checks of expressions, fields, variables, and bookmarks. Use `qlix dsl ui-schema` to export the acceptance suite schema. To run a compiled manifest, use `qlix dsl ui-run manifest.json --driver /path/to/trusted-driver.mjs --output report.json` (requires Node.js).
211
+ Since 0.3.4, `dsl compile --summary` prints a validated
212
+ sheet and object inventory and `--output PATH` writes JSON to a new private
213
+ file. The parent directory must exist. Existing paths, including source aliases,
214
+ are refused. These flags can be combined; use `--indent N` to change JSON
215
+ indentation. `--check` cannot be combined with `--summary` or `--output`.
216
+
217
+ Compilation, field auditing, UI manifest generation, planning, and apply preview are offline. `dsl plan` exits 2 when the plan has conflicts (the JSON is still printed); scripts should also check that the JSON status is `reviewable` before passing the plan to apply. `validate-expressions` uses the named broker for metadata-only checks of expressions, fields, variables, and bookmarks. Use `qlix dsl ui-schema` to export the acceptance suite schema. To run a compiled manifest, use `qlix dsl ui-run manifest.json --driver /path/to/trusted-driver.mjs --output report.json` (requires Node.js).
212
218
 
213
219
  The driver is executable local code, not a downloaded manifest dependency. It exports `async withTab({baseUrl, appId}, run)`, supplies an authenticated tab on the intended disposable app's sheet, awaits `run(tab)` once, and owns cleanup. The tab must expose `playwright`, `goto`, `reload`, `getAXState`, and `dev.logs` as used by the packaged runner. Keep driver stdout clear. The CLI writes a new private report and exits nonzero on assertion failure. It does not open a browser, start SSO, or manage Qlik slots on the driver's behalf; use a driver that reuses the authorized browser session. This integration is tested offline, not live.
214
220
 
@@ -0,0 +1,24 @@
1
+ # Acceptance fixture for `qlix app export`
2
+
3
+ Non-empty variable and bookmark inventories were verified separately on an unpublished synthetic app. The remaining check is whether export includes two independently known **published and community sheets**. Prefer an existing, authorized test app; do not create or publish sheets just for this check. Fixture creation, edits and publication need separate approval.
4
+
5
+ ## Record expected visibility independently
6
+
7
+ Use a test app with one known base/published sheet and one community sheet that the export identity is authorized to see. Record the app UUID, the identity, and both distinct sheet IDs. Verify the sheet categories in Qlik independently; do not infer them from the export. An identity that cannot see the community sheet is a separate test case, not evidence that the object is missing from the app.
8
+
9
+ ## Run the read-only check
10
+
11
+ Use a trusted local policy granting only `read` on this app UUID and a Qlikfile target named `fixture` targeting it. From the checkout, using the build under test:
12
+
13
+ ```sh
14
+ umask 077
15
+ work=$(mktemp -d)
16
+ qlix app export Qlikfile.toml --target fixture --output "$work/frontend.json" &&
17
+ python3 scripts/check-export-fixture.py "$work/frontend.json" \
18
+ --app "$APP_ID" --published-sheet "$BASE_SHEET_ID" \
19
+ --community-sheet "$COMMUNITY_SHEET_ID" --sheets-only
20
+ ```
21
+
22
+ The verifier reports booleans for both sheet IDs, app binding, and scope. A pass establishes that this identity exported the **known fixture sheets**, not that all published/community objects are visible or that the exporter can classify sheets. The export must still report `publishedAndCommunityCoverage: not_verified`. Keep raw artifacts private; retain only the result and fixture scope as evidence.
23
+
24
+ To recheck the full synthetic fixture, use an authorized test app that also has a non-reserved `vQlxExportFixture` variable with definition `314159` and a synthetic bookmark whose ID is known independently. Export to a fresh path with `--include-variables --include-bookmarks` and pass `--bookmark "$BOOKMARK_ID"` to the verifier instead of `--sheets-only`. This is not required for the sheet-visibility check.
@@ -4,7 +4,7 @@ build-backend = "hatchling.build"
4
4
 
5
5
  [project]
6
6
  name = "qlix"
7
- version = "0.3.2"
7
+ version = "0.3.4"
8
8
  description = "CLI-centric Qlik Sense Engine API client, script manager, and declarative frontend DSL"
9
9
  readme = "README.md"
10
10
  license = "MIT"
@@ -14,7 +14,13 @@ def main() -> int:
14
14
  parser.add_argument("--app", required=True, type=UUID)
15
15
  parser.add_argument("--published-sheet", required=True)
16
16
  parser.add_argument("--community-sheet", required=True)
17
- parser.add_argument("--bookmark", required=True)
17
+ mode = parser.add_mutually_exclusive_group(required=True)
18
+ mode.add_argument(
19
+ "--bookmark", help="Check the full synthetic fixture, including this bookmark"
20
+ )
21
+ mode.add_argument(
22
+ "--sheets-only", action="store_true", help="Check a default export without opt-in metadata"
23
+ )
18
24
  args = parser.parse_args()
19
25
  if args.published_sheet == args.community_sheet:
20
26
  parser.error("The two fixture sheet IDs must be different.")
@@ -25,8 +31,7 @@ def main() -> int:
25
31
  scope = bundle["scope"]
26
32
  app = str(args.app)
27
33
  sheets = {sheet["id"] for sheet in snapshot["sheets"]}
28
- variables = bundle["variables"]
29
- bookmarks = bundle["bookmarks"]
34
+ omitted = scope["omitted"]
30
35
  checks = {
31
36
  "format": bundle["kind"] == "qlix/frontend-export" and bundle["schemaVersion"] == 1,
32
37
  "app_binding": all(
@@ -35,16 +40,26 @@ def main() -> int:
35
40
  ),
36
41
  "published_fixture_visible": args.published_sheet in sheets,
37
42
  "community_fixture_visible": args.community_sheet in sheets,
38
- "variable_definition": [
39
- row["definition"] for row in variables if row["name"] == "vQlxExportFixture"
40
- ]
41
- == ["314159"],
42
- "bookmark_visible": any(row["id"] == args.bookmark for row in bookmarks),
43
- "bookmark_metadata_only": (
44
- "bookmarkSelections" in scope["omitted"]
45
- and all(set(row) == {"id", "title"} for row in bookmarks)
46
- ),
43
+ "coverage_not_claimed": scope["publishedAndCommunityCoverage"] == "not_verified",
47
44
  }
45
+ if args.sheets_only:
46
+ checks["opt_in_metadata_omitted"] = all(
47
+ key in omitted and key not in bundle for key in ("variables", "bookmarks")
48
+ )
49
+ else:
50
+ variables = bundle["variables"]
51
+ bookmarks = bundle["bookmarks"]
52
+ checks.update(
53
+ variable_definition=[
54
+ row["definition"] for row in variables if row["name"] == "vQlxExportFixture"
55
+ ]
56
+ == ["314159"],
57
+ bookmark_visible=any(row["id"] == args.bookmark for row in bookmarks),
58
+ bookmark_metadata_only=(
59
+ "bookmarkSelections" in omitted
60
+ and all(set(row) == {"id", "title"} for row in bookmarks)
61
+ ),
62
+ )
48
63
  except (OSError, ValueError, KeyError, TypeError, AttributeError):
49
64
  print(json.dumps({"error": "Invalid or incomplete export fixture artifact."}))
50
65
  return 1
@@ -26,4 +26,4 @@ Use UUIDs and default JSON for automation; `--table` is for interactive reading.
26
26
  ## Read statuses, not just exit codes
27
27
 
28
28
  - Target-aware `app` commands use exit `1` for runtime, policy, or configuration errors and `2` for check failures, conflicts, or drift. A `0` from `app check` can still mean `not_verified`; a `0` from `app plan` can still need review.
29
- - Legacy `dsl plan` can exit `0` with `status: conflicts`; require `status: reviewable` before considering apply. Read the actual phase and JSON status before reporting success.
29
+ - `dsl plan` exits `2` with `status: conflicts` and `0` with `status: reviewable`; still require `status: reviewable` before considering apply. Read the actual phase and JSON status before reporting success.
@@ -795,7 +795,7 @@ async def serve(
795
795
 
796
796
  state = await capture_live(doc)
797
797
  snapshot, library = inspection_documents(state, app)
798
- return {"snapshot": snapshot, "library": library}
798
+ return {"snapshot": snapshot, "library": library, "state": state}
799
799
  if op == "model":
800
800
  from qlix.model import read_model
801
801
 
@@ -14,7 +14,7 @@ from typing import Any
14
14
  from uuid import UUID
15
15
 
16
16
  from . import broker
17
- from .exit_codes import EXIT_ERROR
17
+ from .exit_codes import EXIT_CHECK_FAILED, EXIT_ERROR
18
18
  from .inventory_cli import (
19
19
  INVENTORY_HELP,
20
20
  add_app_selector,
@@ -147,7 +147,11 @@ def _parser() -> argparse.ArgumentParser:
147
147
  operations = dsl.add_subparsers(dest="dsl_op", required=True)
148
148
  compile_cmd = operations.add_parser("compile")
149
149
  compile_cmd.add_argument("spec", type=Path)
150
- compile_cmd.add_argument("--check", action="store_true", help="validate without JSON output")
150
+ compile_mode = compile_cmd.add_mutually_exclusive_group()
151
+ compile_mode.add_argument("--check", action="store_true", help="validate without JSON output")
152
+ compile_mode.add_argument("--summary", action="store_true", help="print a validated inventory")
153
+ compile_cmd.add_argument("-o", "--output", type=Path, help="write JSON to a new private file")
154
+ compile_cmd.add_argument("--indent", type=int, default=2, help="JSON indentation (default: 2)")
151
155
  operations.add_parser("schema")
152
156
  operations.add_parser("ui-schema", help="print the UI acceptance suite JSON Schema")
153
157
  ui_run = operations.add_parser(
@@ -293,7 +297,6 @@ def _read_broker_input(path: Path) -> str:
293
297
 
294
298
 
295
299
  def _dsl(args: argparse.Namespace) -> Any:
296
- from .dsl.compiler import compile_spec_to_dict
297
300
  from .dsl.planner import load_plan_json, plan_frontend
298
301
  from .dsl.schema import frontend_json_schema
299
302
  from .dsl.spec import QlikSpecError, parse_spec
@@ -302,8 +305,18 @@ def _dsl(args: argparse.Namespace) -> Any:
302
305
  if args.dsl_op == "schema":
303
306
  return frontend_json_schema()
304
307
  if args.dsl_op == "compile":
305
- compiled = compile_spec_to_dict(args.spec)
306
- return None if args.check else compiled
308
+ from .compile_frontend import compile_frontend
309
+
310
+ sys.stdout.write(
311
+ compile_frontend(
312
+ args.spec,
313
+ check=args.check,
314
+ summary=args.summary,
315
+ output=args.output,
316
+ indent=args.indent,
317
+ )
318
+ )
319
+ return None
307
320
  if args.dsl_op == "validate-fields":
308
321
  from .field_check import check_fields
309
322
 
@@ -569,6 +582,8 @@ def _run(args: argparse.Namespace) -> Any:
569
582
  directory.mkdir(mode=0o700)
570
583
  write_private_json(directory / "app.json", result["snapshot"])
571
584
  write_private_json(directory / "library.json", result["library"])
585
+ # Full Engine inventory, for repair tools that compare against live state.
586
+ write_private_json(directory / "state.json", result["state"])
572
587
  return {"appId": str(args.app), "outputDir": str(directory)}
573
588
  return broker.run_command(args)
574
589
 
@@ -630,6 +645,8 @@ def main(argv: list[str] | None = None) -> int:
630
645
  print(json.dumps(result, indent=2, ensure_ascii=False, allow_nan=False))
631
646
  if args.op == "dsl" and args.dsl_op == "ui-run" and result["passed"] is not True:
632
647
  return 1
648
+ if args.op == "dsl" and args.dsl_op == "plan" and result["status"] == "conflicts":
649
+ return EXIT_CHECK_FAILED
633
650
  if (
634
651
  (args.op == "script" and args.script_op == "check")
635
652
  or (args.op == "dsl" and args.dsl_op in {"validate-fields", "validate-expressions"})
@@ -0,0 +1,49 @@
1
+ """Offline CLI views of a compiled frontend specification."""
2
+
3
+ import json
4
+ from pathlib import Path
5
+
6
+ from .artifacts import durable_bytes
7
+ from .dsl.compiler import compile_spec
8
+ from .dsl.spec import FrontendSpec, parse_spec
9
+
10
+
11
+ def _summary(spec: FrontendSpec) -> str:
12
+ lines = [
13
+ f"App: {spec.app} (schema v{spec.version})",
14
+ f"Masters: {len(spec.dimensions)} dimensions, {len(spec.measures)} measures",
15
+ ]
16
+ for key, sheet in spec.resolved_sheets():
17
+ objects = sheet.resolved_objects()
18
+ lines.append(f"Sheet {key} ({len(objects)} objects, grid {sheet.grid[0]}x{sheet.grid[1]}):")
19
+ parents = sheet.container_parents()
20
+ for object_key, obj in objects:
21
+ if obj.position is None:
22
+ placement = f"in={parents[object_key]}"
23
+ else:
24
+ placement = "pos=[" + ",".join(str(value) for value in obj.position) + "]"
25
+ lines.append(
26
+ f" {object_key:24s} {obj.type:15s} {placement} "
27
+ f"dims={len(obj.resolved_dimensions())} meas={len(obj.resolved_measures())} "
28
+ f"{obj.title or ''}"
29
+ )
30
+ return "\n".join(lines) + "\n"
31
+
32
+
33
+ def compile_frontend(
34
+ source: Path, *, check: bool, summary: bool, output: Path | None, indent: int
35
+ ) -> str:
36
+ if check and output is not None:
37
+ raise ValueError("--check cannot be combined with --output.")
38
+ spec = parse_spec(source)
39
+ compiled = compile_spec(spec)
40
+ if check:
41
+ return ""
42
+ overview = _summary(spec) if summary else ""
43
+ if summary and output is None:
44
+ return overview
45
+ payload = json.dumps(compiled, indent=indent, ensure_ascii=False, allow_nan=False) + "\n"
46
+ if output is not None:
47
+ durable_bytes(output, payload.encode("utf-8"))
48
+ return overview
49
+ return payload
@@ -334,6 +334,9 @@ class Lifecycle(unittest.TestCase):
334
334
  self.assertEqual(json.loads(snapshot.read_text())["modelFields"], ["demo"])
335
335
  self.assertEqual(snapshot.stat().st_mode & 0o777, 0o600)
336
336
  self.assertEqual(output.stat().st_mode & 0o777, 0o700)
337
+ state = json.loads((output / "state.json").read_text())
338
+ self.assertEqual(set(state) >= {"objects", "masters", "modelFields"}, True)
339
+ self.assertEqual((output / "state.json").stat().st_mode & 0o777, 0o600)
337
340
  self._call(env, "inspect", "--app", app, "--output-dir", str(output), ok=False)
338
341
  spec = str(PACKAGE.parents[1] / "examples/synthetic-smoke.yaml")
339
342
  self.assertTrue(