tripl 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.
- tripl-0.3.4/Dockerfile +66 -0
- {tripl-0.3.2 → tripl-0.3.4}/PKG-INFO +35 -9
- {tripl-0.3.2 → tripl-0.3.4}/README.md +34 -8
- tripl-0.3.4/examples/checkout/README.md +22 -0
- tripl-0.3.4/examples/checkout/checkout.py +28 -0
- tripl-0.3.4/examples/compatibility/orders.json +13 -0
- {tripl-0.3.2 → tripl-0.3.4}/pyproject.toml +1 -1
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/api/__init__.py +4 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/api/branches.py +1 -1
- tripl-0.3.4/src/tripl_cli/api/check_runs.py +48 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/api/endpoints.py +6 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/api/events.py +13 -0
- tripl-0.3.4/src/tripl_cli/api/meta_fields.py +10 -0
- tripl-0.3.4/src/tripl_cli/api/plan_revisions.py +32 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/api/plan_validation.py +15 -2
- tripl-0.3.4/src/tripl_cli/check/__init__.py +23 -0
- tripl-0.3.4/src/tripl_cli/check/baseline.py +485 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/check/calls.py +51 -3
- tripl-0.3.4/src/tripl_cli/check/changes.py +666 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/check/config.py +153 -5
- tripl-0.3.4/src/tripl_cli/check/coverage.py +203 -0
- tripl-0.3.4/src/tripl_cli/check/fingerprint.py +120 -0
- tripl-0.3.4/src/tripl_cli/check/gate.py +698 -0
- tripl-0.3.4/src/tripl_cli/check/inventory.py +1319 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/check/lexer.py +5 -0
- tripl-0.3.4/src/tripl_cli/check/lint.py +212 -0
- tripl-0.3.4/src/tripl_cli/check/listing.py +531 -0
- tripl-0.3.4/src/tripl_cli/check/model.py +585 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/check/payloads.py +16 -11
- tripl-0.3.4/src/tripl_cli/check/places.py +407 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/check/presets.py +28 -3
- tripl-0.3.4/src/tripl_cli/check/render.py +644 -0
- tripl-0.3.4/src/tripl_cli/check/reports.py +293 -0
- tripl-0.3.4/src/tripl_cli/check/scan.py +680 -0
- tripl-0.3.4/src/tripl_cli/check/scopes.py +981 -0
- tripl-0.3.4/src/tripl_cli/check/signatures.py +486 -0
- tripl-0.3.4/src/tripl_cli/check/summary.py +296 -0
- tripl-0.3.4/src/tripl_cli/check/suppress.py +279 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/check/symbols.py +436 -73
- tripl-0.3.4/src/tripl_cli/check/upload.py +384 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/check/validate.py +52 -5
- tripl-0.3.4/src/tripl_cli/check/values.py +1647 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/check/yamlish.py +58 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/cli.py +90 -25
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/codegen/files.py +30 -1
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/commands/__init__.py +25 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/commands/_check_config.py +10 -4
- tripl-0.3.4/src/tripl_cli/commands/_plan.py +336 -0
- tripl-0.3.4/src/tripl_cli/commands/check.py +1462 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/commands/codegen.py +39 -13
- tripl-0.3.4/src/tripl_cli/commands/compatibility.py +127 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/commands/doctor.py +33 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/commands/export.py +17 -6
- tripl-0.3.4/src/tripl_cli/commands/journey_capture.py +89 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/commands/plan.py +90 -6
- tripl-0.3.4/src/tripl_cli/commands/reproduce.py +191 -0
- tripl-0.3.4/src/tripl_cli/compat_sql.py +147 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/config.py +42 -4
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/diagnostics/endpoints.py +2 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/diagnostics/scan_checks.py +4 -3
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/errors.py +35 -1
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/install/files/compose.yaml +37 -2
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/install/shell.py +48 -18
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/model.py +19 -13
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/render.py +110 -6
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/report.py +394 -22
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/runner.py +29 -0
- tripl-0.3.4/src/tripl_cli/streams.py +103 -0
- tripl-0.3.4/src/tripl_cli/support_report.py +139 -0
- tripl-0.3.4/tests/check_golden/no-marker.codequality.json +70 -0
- tripl-0.3.4/tests/check_golden/no-marker.junit.xml +6 -0
- tripl-0.3.4/tests/check_golden/no-marker.sarif.json +233 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/conftest.py +58 -1
- tripl-0.3.4/tests/journey_fixture/candidate.json +19 -0
- tripl-0.3.4/tests/journey_fixture/healthy.json +19 -0
- tripl-0.3.4/tests/journey_fixture/suspect.json +17 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/test_api_requests.py +7 -0
- tripl-0.3.4/tests/test_check_baseline.py +847 -0
- tripl-0.3.4/tests/test_check_changes.py +687 -0
- tripl-0.3.4/tests/test_check_cmd.py +2821 -0
- tripl-0.3.4/tests/test_check_coverage.py +304 -0
- tripl-0.3.4/tests/test_check_gate.py +387 -0
- tripl-0.3.4/tests/test_check_gate_cmd.py +1779 -0
- tripl-0.3.4/tests/test_check_lint.py +709 -0
- tripl-0.3.4/tests/test_check_list_doc_samples.py +208 -0
- tripl-0.3.4/tests/test_check_list_suppressions.py +289 -0
- tripl-0.3.4/tests/test_check_payload_doc_samples.py +142 -0
- tripl-0.3.4/tests/test_check_plan_branch_fallback.py +408 -0
- tripl-0.3.4/tests/test_check_reports.py +803 -0
- tripl-0.3.4/tests/test_check_revision.py +138 -0
- tripl-0.3.4/tests/test_check_scan.py +4651 -0
- tripl-0.3.4/tests/test_check_scan_choices.py +583 -0
- tripl-0.3.4/tests/test_check_summary.py +228 -0
- tripl-0.3.4/tests/test_check_suppress.py +512 -0
- tripl-0.3.4/tests/test_check_upload.py +727 -0
- tripl-0.3.4/tests/test_ci_templates.py +835 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/test_codegen_cmd.py +249 -0
- tripl-0.3.4/tests/test_compat_sql.py +92 -0
- tripl-0.3.4/tests/test_compatibility_cmd.py +66 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/test_config.py +55 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/test_contract.py +185 -6
- tripl-0.3.4/tests/test_journey_capture.py +94 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/test_output_samples.py +344 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/test_plan_cmd.py +197 -5
- tripl-0.3.4/tests/test_reproduce.py +214 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/test_runner.py +24 -0
- tripl-0.3.4/tests/test_streams.py +313 -0
- tripl-0.3.4/tests/test_support_report.py +209 -0
- {tripl-0.3.2 → tripl-0.3.4}/uv.lock +70 -70
- tripl-0.3.2/src/tripl_cli/check/__init__.py +0 -18
- tripl-0.3.2/src/tripl_cli/check/model.py +0 -121
- tripl-0.3.2/src/tripl_cli/check/render.py +0 -254
- tripl-0.3.2/src/tripl_cli/check/scan.py +0 -367
- tripl-0.3.2/src/tripl_cli/check/values.py +0 -393
- tripl-0.3.2/src/tripl_cli/commands/_plan.py +0 -164
- tripl-0.3.2/src/tripl_cli/commands/check.py +0 -189
- tripl-0.3.2/tests/test_check_cmd.py +0 -640
- tripl-0.3.2/tests/test_check_scan.py +0 -639
- {tripl-0.3.2 → tripl-0.3.4}/.gitignore +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/LICENSE +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/__init__.py +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/__main__.py +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/api/auth.py +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/api/chart_annotations.py +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/api/data_sources.py +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/api/docs.py +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/api/event_types.py +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/api/monitoring.py +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/api/plan_export.py +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/api/projects.py +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/api/request.py +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/api/scans.py +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/api/search.py +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/api/variables.py +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/client.py +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/codegen/__init__.py +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/codegen/calls.py +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/codegen/context.py +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/codegen/context_named.py +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/codegen/context_plan.py +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/codegen/generate.py +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/codegen/languages.py +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/codegen/model.py +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/codegen/naming.py +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/codegen/template.py +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/codegen/templates/named.kotlin.mustache +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/codegen/templates/named.swift.mustache +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/codegen/templates/named.ts.mustache +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/codegen/templates/screen_view.kotlin.mustache +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/codegen/templates/screen_view.swift.mustache +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/codegen/templates/screen_view.ts.mustache +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/codegen/templates/self_describing.kotlin.mustache +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/codegen/templates/self_describing.swift.mustache +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/codegen/templates/self_describing.ts.mustache +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/codegen/templates/structured.kotlin.mustache +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/codegen/templates/structured.swift.mustache +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/codegen/templates/structured.ts.mustache +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/codegen/templates/transport.kotlin.mustache +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/codegen/templates/transport.swift.mustache +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/codegen/templates/transport.ts.mustache +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/codegen/value_types.py +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/commands/_docs_files.py +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/commands/_resolve.py +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/commands/_write.py +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/commands/annotate.py +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/commands/docs.py +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/commands/drifts.py +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/commands/events.py +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/commands/install.py +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/commands/scans.py +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/commands/status.py +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/commands/upgrade.py +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/commands/watch.py +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/commands/whoami.py +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/diagnostics/__init__.py +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/diagnostics/checks.py +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/diagnostics/collect.py +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/install/__init__.py +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/install/docker.py +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/install/files/rabbitmq.conf +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/install/files.py +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/install/health.py +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/install/plan.py +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/install/render.py +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/install/secrets.py +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/py.typed +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/watch/__init__.py +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/watch/collect.py +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/watch/diff.py +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/watch/loop.py +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/watch/model.py +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/src/tripl_cli/watch/render.py +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/__init__.py +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/codegen/check.yml +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/codegen/custom/check.yml +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/codegen/custom/golden/kotlin/AcmeAction.kt +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/codegen/custom/golden/kotlin/AcmeAppConstants.kt +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/codegen/custom/golden/kotlin/AcmeCategory.kt +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/codegen/custom/golden/kotlin/AcmeLabel.kt +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/codegen/custom/golden/kotlin/AcmeProperty.kt +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/codegen/custom/golden/kotlin/AcmeScreens.kt +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/codegen/custom/golden/kotlin/AcmeStructured.kt +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/codegen/custom/golden/kotlin/TriplTransport.kt +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/codegen/custom/golden/swift/AcmeAppConstants.swift +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/codegen/custom/golden/swift/AcmePlanned.swift +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/codegen/custom/golden/swift/AcmeScreens.swift +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/codegen/custom/golden/swift/AcmeStructured.swift +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/codegen/custom/golden/swift/TriplTransport.swift +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/codegen/custom/golden/ts/acmeAction.ts +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/codegen/custom/golden/ts/acmeAppConstants.ts +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/codegen/custom/golden/ts/acmeCategory.ts +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/codegen/custom/golden/ts/acmeLabel.ts +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/codegen/custom/golden/ts/acmeProperty.ts +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/codegen/custom/golden/ts/acmeScreens.ts +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/codegen/custom/golden/ts/acmeStructured.ts +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/codegen/custom/golden/ts/triplTransport.ts +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/codegen/custom/model.json +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/codegen/custom/templates/holder.kotlin.mustache +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/codegen/custom/templates/holder.ts.mustache +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/codegen/custom/templates/named.kotlin.mustache +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/codegen/custom/templates/named.swift.mustache +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/codegen/custom/templates/named.ts.mustache +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/codegen/custom/templates/planned.swift.mustache +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/codegen/custom/templates/screen.kotlin.mustache +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/codegen/custom/templates/screen.swift.mustache +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/codegen/custom/templates/screen.ts.mustache +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/codegen/custom/templates/structured.kotlin.mustache +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/codegen/custom/templates/structured.swift.mustache +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/codegen/custom/templates/structured.ts.mustache +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/codegen/golden/kotlin/AppEvents.kt +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/codegen/golden/kotlin/LegacyTracking.kt +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/codegen/golden/kotlin/ScreenTracking.kt +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/codegen/golden/kotlin/SdTracking.kt +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/codegen/golden/kotlin/TriplTransport.kt +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/codegen/golden/swift/AppEvents.swift +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/codegen/golden/swift/LegacyTracking.swift +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/codegen/golden/swift/ScreenTracking.swift +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/codegen/golden/swift/SdTracking.swift +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/codegen/golden/swift/TriplTransport.swift +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/codegen/golden/ts/appEvents.ts +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/codegen/golden/ts/legacyTracking.ts +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/codegen/golden/ts/screenTracking.ts +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/codegen/golden/ts/sdTracking.ts +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/codegen/golden/ts/triplTransport.ts +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/codegen/model.json +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/test_annotate_cmd.py +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/test_check_config_flags.py +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/test_checks.py +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/test_cli.py +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/test_client.py +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/test_client_redirects.py +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/test_codegen_custom.py +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/test_codegen_generate.py +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/test_codegen_naming.py +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/test_codegen_template.py +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/test_compose_env.py +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/test_docker_detect.py +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/test_docs_audience.py +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/test_docs_cmd.py +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/test_docs_cover_the_parser.py +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/test_doctor.py +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/test_drifts_cmd.py +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/test_events_cmd.py +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/test_install_cmd.py +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/test_install_files.py +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/test_install_version_recovery.py +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/test_scans_cmd.py +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/test_status.py +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/test_upgrade_cmd.py +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/test_watch.py +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/test_watch_diff.py +0 -0
- {tripl-0.3.2 → tripl-0.3.4}/tests/test_whoami_cmd.py +0 -0
tripl-0.3.4/Dockerfile
ADDED
|
@@ -0,0 +1,66 @@
|
|
|
1
|
+
# The tripl CLI for CI jobs, published as ghcr.io/tripl-io/tripl-cli by
|
|
2
|
+
# publish-cli.yml on every cli-v* tag: Python, `tripl` on PATH, git and a shell,
|
|
3
|
+
# and no ENTRYPOINT, so GitLab CI, Bitbucket Pipelines, Jenkins, CircleCI or Azure
|
|
4
|
+
# Pipelines run a job's script in it as they would in python:3.x-slim, without
|
|
5
|
+
# installing the CLI from PyPI on every run.
|
|
6
|
+
#
|
|
7
|
+
# Build context is the REPOSITORY ROOT, not cli/, for the license-notice script
|
|
8
|
+
# under backend/scripts: `docker build -f cli/Dockerfile .`. ci.yml and
|
|
9
|
+
# publish-cli.yml both pass context `.`.
|
|
10
|
+
|
|
11
|
+
# Pinned on purpose: :latest makes the image non-reproducible. A stage of its
|
|
12
|
+
# own rather than `COPY --from=<image>` because Dependabot bumps FROM lines
|
|
13
|
+
# only. Bump it together with the uv images of the root Dockerfile,
|
|
14
|
+
# backend/Dockerfile and mcp-server/Dockerfile.
|
|
15
|
+
FROM ghcr.io/astral-sh/uv:0.13.8 AS uv
|
|
16
|
+
|
|
17
|
+
FROM python:3.14-slim-trixie AS build
|
|
18
|
+
|
|
19
|
+
COPY --from=uv /uv /usr/local/bin/uv
|
|
20
|
+
|
|
21
|
+
WORKDIR /app/cli
|
|
22
|
+
# No Python downloads: the venv must run on this stage's interpreter, which the
|
|
23
|
+
# runtime stage has at the same path. A Python uv fetched would stay behind here.
|
|
24
|
+
ENV UV_COMPILE_BYTECODE=1 UV_LINK_MODE=copy UV_PYTHON_DOWNLOADS=never
|
|
25
|
+
|
|
26
|
+
# What uv builds the package from: pyproject.toml, src/, README.md (declared as
|
|
27
|
+
# `readme`) and LICENSE.
|
|
28
|
+
COPY cli/pyproject.toml cli/uv.lock cli/README.md cli/LICENSE ./
|
|
29
|
+
COPY cli/src ./src
|
|
30
|
+
# --locked, like CI: it fails on a uv.lock that no longer describes
|
|
31
|
+
# pyproject.toml. --no-editable installs the package itself into the venv, so
|
|
32
|
+
# the runtime stage needs neither the source nor uv.
|
|
33
|
+
RUN uv sync --locked --no-dev --no-editable
|
|
34
|
+
|
|
35
|
+
FROM python:3.14-slim-trixie
|
|
36
|
+
|
|
37
|
+
COPY --from=build /app/cli/.venv /app/cli/.venv
|
|
38
|
+
# A CI log shows stdout and stderr in the order the CLI wrote them.
|
|
39
|
+
ENV PATH="/app/cli/.venv/bin:$PATH" PYTHONUNBUFFERED=1
|
|
40
|
+
|
|
41
|
+
# git, for `tripl check --new-from-rev`, which diffs the checkout against the
|
|
42
|
+
# merge request's base commit, and for the `git fetch` of that commit a job
|
|
43
|
+
# runs first. Git alone: no recommends (no ssh client, no perl, no less).
|
|
44
|
+
# Before the license notices, so git's own Debian notice is collected with the
|
|
45
|
+
# rest. A job running under a uid that does not own its checkout gets git's
|
|
46
|
+
# "dubious ownership" refusal as an exit 2 with the safe.directory command to
|
|
47
|
+
# run; nothing here sets safe.directory for it.
|
|
48
|
+
RUN apt-get update \
|
|
49
|
+
&& apt-get install -y --no-install-recommends git \
|
|
50
|
+
&& rm -rf /var/lib/apt/lists/*
|
|
51
|
+
|
|
52
|
+
# Third-party license notices for the venv and the Debian packages (git
|
|
53
|
+
# included), in /app/licenses (README.md is the index).
|
|
54
|
+
RUN --mount=type=bind,source=backend/scripts/third_party_licenses.py,target=/tmp/third_party_licenses.py \
|
|
55
|
+
/app/cli/.venv/bin/python /tmp/third_party_licenses.py --out /app/licenses
|
|
56
|
+
|
|
57
|
+
# Root, unlike the service images and like the python:3.x-slim images CI jobs
|
|
58
|
+
# use: a job writes its reports into a workspace that belongs to the runner,
|
|
59
|
+
# and a uid of this image's own could not where a runner mounts that workspace
|
|
60
|
+
# from the host and keeps the image's user (GitHub's container jobs, for one).
|
|
61
|
+
# The image serves nothing; each job runs one command in it and exits.
|
|
62
|
+
#
|
|
63
|
+
# For `docker run --rm -v "$PWD:/src" ghcr.io/tripl-io/tripl-cli tripl check`;
|
|
64
|
+
# a CI job runs in its own checkout directory instead.
|
|
65
|
+
WORKDIR /src
|
|
66
|
+
CMD ["tripl", "--help"]
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.5
|
|
2
2
|
Name: tripl
|
|
3
|
-
Version: 0.3.
|
|
3
|
+
Version: 0.3.4
|
|
4
4
|
Summary: Command-line client for tripl: instance diagnostics and live monitoring, tracking-plan reads, code checks and codegen against the plan, team notes, and self-hosted install and upgrade
|
|
5
5
|
Project-URL: Homepage, https://docs.tripl.io/
|
|
6
6
|
Project-URL: Documentation, https://docs.tripl.io/run/cli
|
|
@@ -73,6 +73,14 @@ uvx tripl --version
|
|
|
73
73
|
pip install tripl
|
|
74
74
|
```
|
|
75
75
|
|
|
76
|
+
In a container — `ghcr.io/tripl-io/tripl-cli` is the CLI on Python, with git,
|
|
77
|
+
a shell and no entrypoint, for CI jobs that run in an image (tagged `X.Y.Z`,
|
|
78
|
+
`X.Y` and `latest` from the release after v0.3.2):
|
|
79
|
+
|
|
80
|
+
```bash
|
|
81
|
+
docker run --rm ghcr.io/tripl-io/tripl-cli:X.Y.Z tripl --version
|
|
82
|
+
```
|
|
83
|
+
|
|
76
84
|
From a local checkout, when you are working on the CLI itself:
|
|
77
85
|
|
|
78
86
|
```bash
|
|
@@ -101,6 +109,7 @@ prints that group's help on stderr and exits 2.
|
|
|
101
109
|
tripl doctor # check the instance and report what is broken
|
|
102
110
|
tripl doctor --json # one JSON document on stdout, human lines on stderr
|
|
103
111
|
tripl doctor --strict # exit 3 on warnings too (never on skipped checks)
|
|
112
|
+
tripl doctor --support-report ./tripl-support.json # privacy-safe file to attach to a support request
|
|
104
113
|
tripl status # projects, events, scans, signals, coverage
|
|
105
114
|
tripl whoami # the account, organization and scope the API key acts as
|
|
106
115
|
tripl watch # follow jobs, signals and delivery failures live
|
|
@@ -118,11 +127,15 @@ tripl plan types --project SLUG # event types, with a field count ea
|
|
|
118
127
|
tripl plan fields <event-type> --project SLUG # one event type's field definitions
|
|
119
128
|
tripl plan properties --project SLUG # properties, and how many events use each
|
|
120
129
|
tripl plan branches --project SLUG # plan branches and how far ahead each is
|
|
130
|
+
tripl plan revisions --project SLUG # stored plan revisions; the id check --revision takes
|
|
121
131
|
tripl plan search <query> --project SLUG # search the whole plan, ids to read next
|
|
122
132
|
tripl annotate "Deployed web 2026.09.25" --project SLUG --url URL # deploy marker on monitoring charts (WRITE)
|
|
123
133
|
tripl check # validate the tracking calls in this checkout against the plan
|
|
134
|
+
tripl check --list # what the scan reads from each call, and why a value is not read; no key, sends nothing
|
|
124
135
|
tripl check --payloads events.ndjson # validate captured events; a missing required field fails
|
|
125
136
|
tripl check --format sarif > tripl.sarif # SARIF 2.1.0 for code scanning
|
|
137
|
+
tripl check --report codequality=gl-code-quality-report.json --report junit=tripl-check.xml # a GitLab merge request's reports
|
|
138
|
+
tripl check --new-from-rev "$BASE" # fail only on findings new since the commit BASE (or --new-from-patch FILE)
|
|
126
139
|
tripl codegen # typed tracking code (Swift, Kotlin, TypeScript) from the plan
|
|
127
140
|
tripl codegen --check # CI: exit 1 when the committed generated files are out of date
|
|
128
141
|
tripl export --out plan-schemas # one JSON Schema (2020-12) per event, plus the bundle
|
|
@@ -189,7 +202,8 @@ event_types:
|
|
|
189
202
|
```
|
|
190
203
|
|
|
191
204
|
Presets: `segment_track`, `amplitude_log_event`, `snowplow_structured`,
|
|
192
|
-
`snowplow_screen_view`, `snowplow_self_describing
|
|
205
|
+
`snowplow_screen_view`, `snowplow_self_describing` (`tripl check --print-preset
|
|
206
|
+
NAME` prints one as YAML, to start your own from). Swift, Objective-C, Kotlin,
|
|
193
207
|
Java and TypeScript/JavaScript are read; enum shorthand (`.home`) and qualified
|
|
194
208
|
cases resolve through the enum files, interpolated names become plan properties
|
|
195
209
|
(`"promo_sheet_\(id)_shown"` is `promo_sheet_${id}_shown`), Kotlin/Java
|
|
@@ -399,20 +413,26 @@ not moved).
|
|
|
399
413
|
| Exit | Meaning |
|
|
400
414
|
|------|---------|
|
|
401
415
|
| 0 | Every check passed, or only warned and `--strict` was not given. `status` and `whoami`, whenever they completed. `watch`, whenever the run completed — a failed job or a new signal is still 0. The `scans`, `drifts`, `events`, `plan` and `docs` verbs and `annotate`, whenever every read arrived or the write was accepted (`--dry-run` included, and a de-duplicated `annotate` too). |
|
|
402
|
-
| 1 | The tool itself broke (doctor turns every API failure into a finding), or any other command could not complete a request — unreachable, or the API refused it. For `watch` this includes a key revoked mid-run. For `scans list` / `drifts list` it includes **any** failed read in the fan-out; for `scans run`, a job returned already `failed`; for `scans cancel` / `drifts dismiss` / `drifts reopen` / `docs push`, a declined prompt. For `install` and `upgrade`, a `docker compose` command that failed or a `/health` that did not answer in time. |
|
|
416
|
+
| 1 | The tool itself broke (doctor turns every API failure into a finding), or any other command could not complete a request — unreachable (4 instead for `check`, `codegen` and `export`), or the API refused it. For `watch` this includes a key revoked mid-run. For `scans list` / `drifts list` it includes **any** failed read in the fan-out; for `scans run`, a job returned already `failed`; for `scans cancel` / `drifts dismiss` / `drifts reopen` / `docs push`, a declined prompt. For `install` and `upgrade`, a `docker compose` command that failed or a `/health` that did not answer in time. |
|
|
403
417
|
| 2 | Usage or configuration error. For `doctor` and `status` that is resolved before any socket opens; `watch` also refuses after reading the listings, when `--scan` matches nothing or more than 24 scan configs are selected. The object verbs add a bare group, a missing or repeated `--project`, an unresolved or ambiguous selector, and a prompting write on a non-TTY without `--yes`; `annotate` adds a `--url` that is not http(s), an `--at` that is not RFC 3339, and half a scope; `upgrade` adds a refused downgrade and an unorderable pair without `--allow-unordered-tag`. Either way **no JSON is emitted** and no write is sent. |
|
|
404
418
|
| 3 | `doctor` only: at least one check failed, or `--strict` and at least one warning. Nothing else ever exits 3. |
|
|
419
|
+
| 4 | `check`, `codegen` and `export` only: the instance was unavailable — unreachable, timed out, `429` or a `5xx` — so nothing was decided and nothing was written. A refused key stays 1, because a retry does not fix it. A CI pipeline can let 4 pass (GitLab: `allow_failure: exit_codes: [4]`) while findings and drift still block. |
|
|
405
420
|
| 130 | Interrupted (SIGINT). For `watch` this is the **normal** ending — a run without `--duration` has no other way to stop. |
|
|
406
421
|
|
|
407
|
-
`check` uses 0, 1 and
|
|
408
|
-
`--strict`, a warning),
|
|
409
|
-
`
|
|
410
|
-
|
|
422
|
+
`check` uses 0, 1, 2 and 4: 1 when any call site or event has an error (or,
|
|
423
|
+
with `--strict`, a warning) or, with `--strict-suppressions`, a
|
|
424
|
+
`tripl-check-ignore` marker is malformed or unused, 2 for a bad check config or payload file, or a
|
|
425
|
+
config that matches no call (unless `--allow-empty`), and 4 for an unavailable
|
|
426
|
+
instance. `codegen` uses them too: 1 for drift under `--check` (or a plan
|
|
427
|
+
without a configured event type), 2 for a bad check config or template, 4 for
|
|
428
|
+
an unavailable instance; `export` uses 4 the same way.
|
|
411
429
|
|
|
412
430
|
An unreachable instance therefore exits **3** out of `doctor`, not 1 — it
|
|
413
431
|
becomes a finding like everything else doctor reads, which is what makes an exit
|
|
414
|
-
1 out of `doctor` a meaningful bug signal.
|
|
415
|
-
|
|
432
|
+
1 out of `doctor` a meaningful bug signal. `check`, `codegen` and `export` exit
|
|
433
|
+
**4**, so a pipeline can tell an outage from a finding. **Every other command
|
|
434
|
+
exits 1** on an unreachable instance, because none of them turns a failed read
|
|
435
|
+
into a verdict.
|
|
416
436
|
|
|
417
437
|
`doctor` and `status` put exactly one JSON document on stdout, and so does every
|
|
418
438
|
other command except `watch` — but only when the command completes: a write the API
|
|
@@ -492,3 +512,9 @@ uv run --group dev mypy src
|
|
|
492
512
|
than from the published release, so a change here is picked up by
|
|
493
513
|
`cd mcp-server && uv sync` without any install step — and both suites test the
|
|
494
514
|
same source. Run **both** after touching `client.py`.
|
|
515
|
+
|
|
516
|
+
Use `tripl reproduce` to compare synthetic app-test captures from healthy,
|
|
517
|
+
suspect and candidate builds for a tracking incident.
|
|
518
|
+
Create each capture with `tripl journey-capture`.
|
|
519
|
+
|
|
520
|
+
Use `tripl compatibility preview` to compile a bounded historical check of an event rename on a plan branch. After review and merge, `tripl compatibility model` emits the reusable ClickHouse SELECT from the main event.
|
|
@@ -45,6 +45,14 @@ uvx tripl --version
|
|
|
45
45
|
pip install tripl
|
|
46
46
|
```
|
|
47
47
|
|
|
48
|
+
In a container — `ghcr.io/tripl-io/tripl-cli` is the CLI on Python, with git,
|
|
49
|
+
a shell and no entrypoint, for CI jobs that run in an image (tagged `X.Y.Z`,
|
|
50
|
+
`X.Y` and `latest` from the release after v0.3.2):
|
|
51
|
+
|
|
52
|
+
```bash
|
|
53
|
+
docker run --rm ghcr.io/tripl-io/tripl-cli:X.Y.Z tripl --version
|
|
54
|
+
```
|
|
55
|
+
|
|
48
56
|
From a local checkout, when you are working on the CLI itself:
|
|
49
57
|
|
|
50
58
|
```bash
|
|
@@ -73,6 +81,7 @@ prints that group's help on stderr and exits 2.
|
|
|
73
81
|
tripl doctor # check the instance and report what is broken
|
|
74
82
|
tripl doctor --json # one JSON document on stdout, human lines on stderr
|
|
75
83
|
tripl doctor --strict # exit 3 on warnings too (never on skipped checks)
|
|
84
|
+
tripl doctor --support-report ./tripl-support.json # privacy-safe file to attach to a support request
|
|
76
85
|
tripl status # projects, events, scans, signals, coverage
|
|
77
86
|
tripl whoami # the account, organization and scope the API key acts as
|
|
78
87
|
tripl watch # follow jobs, signals and delivery failures live
|
|
@@ -90,11 +99,15 @@ tripl plan types --project SLUG # event types, with a field count ea
|
|
|
90
99
|
tripl plan fields <event-type> --project SLUG # one event type's field definitions
|
|
91
100
|
tripl plan properties --project SLUG # properties, and how many events use each
|
|
92
101
|
tripl plan branches --project SLUG # plan branches and how far ahead each is
|
|
102
|
+
tripl plan revisions --project SLUG # stored plan revisions; the id check --revision takes
|
|
93
103
|
tripl plan search <query> --project SLUG # search the whole plan, ids to read next
|
|
94
104
|
tripl annotate "Deployed web 2026.09.25" --project SLUG --url URL # deploy marker on monitoring charts (WRITE)
|
|
95
105
|
tripl check # validate the tracking calls in this checkout against the plan
|
|
106
|
+
tripl check --list # what the scan reads from each call, and why a value is not read; no key, sends nothing
|
|
96
107
|
tripl check --payloads events.ndjson # validate captured events; a missing required field fails
|
|
97
108
|
tripl check --format sarif > tripl.sarif # SARIF 2.1.0 for code scanning
|
|
109
|
+
tripl check --report codequality=gl-code-quality-report.json --report junit=tripl-check.xml # a GitLab merge request's reports
|
|
110
|
+
tripl check --new-from-rev "$BASE" # fail only on findings new since the commit BASE (or --new-from-patch FILE)
|
|
98
111
|
tripl codegen # typed tracking code (Swift, Kotlin, TypeScript) from the plan
|
|
99
112
|
tripl codegen --check # CI: exit 1 when the committed generated files are out of date
|
|
100
113
|
tripl export --out plan-schemas # one JSON Schema (2020-12) per event, plus the bundle
|
|
@@ -161,7 +174,8 @@ event_types:
|
|
|
161
174
|
```
|
|
162
175
|
|
|
163
176
|
Presets: `segment_track`, `amplitude_log_event`, `snowplow_structured`,
|
|
164
|
-
`snowplow_screen_view`, `snowplow_self_describing
|
|
177
|
+
`snowplow_screen_view`, `snowplow_self_describing` (`tripl check --print-preset
|
|
178
|
+
NAME` prints one as YAML, to start your own from). Swift, Objective-C, Kotlin,
|
|
165
179
|
Java and TypeScript/JavaScript are read; enum shorthand (`.home`) and qualified
|
|
166
180
|
cases resolve through the enum files, interpolated names become plan properties
|
|
167
181
|
(`"promo_sheet_\(id)_shown"` is `promo_sheet_${id}_shown`), Kotlin/Java
|
|
@@ -371,20 +385,26 @@ not moved).
|
|
|
371
385
|
| Exit | Meaning |
|
|
372
386
|
|------|---------|
|
|
373
387
|
| 0 | Every check passed, or only warned and `--strict` was not given. `status` and `whoami`, whenever they completed. `watch`, whenever the run completed — a failed job or a new signal is still 0. The `scans`, `drifts`, `events`, `plan` and `docs` verbs and `annotate`, whenever every read arrived or the write was accepted (`--dry-run` included, and a de-duplicated `annotate` too). |
|
|
374
|
-
| 1 | The tool itself broke (doctor turns every API failure into a finding), or any other command could not complete a request — unreachable, or the API refused it. For `watch` this includes a key revoked mid-run. For `scans list` / `drifts list` it includes **any** failed read in the fan-out; for `scans run`, a job returned already `failed`; for `scans cancel` / `drifts dismiss` / `drifts reopen` / `docs push`, a declined prompt. For `install` and `upgrade`, a `docker compose` command that failed or a `/health` that did not answer in time. |
|
|
388
|
+
| 1 | The tool itself broke (doctor turns every API failure into a finding), or any other command could not complete a request — unreachable (4 instead for `check`, `codegen` and `export`), or the API refused it. For `watch` this includes a key revoked mid-run. For `scans list` / `drifts list` it includes **any** failed read in the fan-out; for `scans run`, a job returned already `failed`; for `scans cancel` / `drifts dismiss` / `drifts reopen` / `docs push`, a declined prompt. For `install` and `upgrade`, a `docker compose` command that failed or a `/health` that did not answer in time. |
|
|
375
389
|
| 2 | Usage or configuration error. For `doctor` and `status` that is resolved before any socket opens; `watch` also refuses after reading the listings, when `--scan` matches nothing or more than 24 scan configs are selected. The object verbs add a bare group, a missing or repeated `--project`, an unresolved or ambiguous selector, and a prompting write on a non-TTY without `--yes`; `annotate` adds a `--url` that is not http(s), an `--at` that is not RFC 3339, and half a scope; `upgrade` adds a refused downgrade and an unorderable pair without `--allow-unordered-tag`. Either way **no JSON is emitted** and no write is sent. |
|
|
376
390
|
| 3 | `doctor` only: at least one check failed, or `--strict` and at least one warning. Nothing else ever exits 3. |
|
|
391
|
+
| 4 | `check`, `codegen` and `export` only: the instance was unavailable — unreachable, timed out, `429` or a `5xx` — so nothing was decided and nothing was written. A refused key stays 1, because a retry does not fix it. A CI pipeline can let 4 pass (GitLab: `allow_failure: exit_codes: [4]`) while findings and drift still block. |
|
|
377
392
|
| 130 | Interrupted (SIGINT). For `watch` this is the **normal** ending — a run without `--duration` has no other way to stop. |
|
|
378
393
|
|
|
379
|
-
`check` uses 0, 1 and
|
|
380
|
-
`--strict`, a warning),
|
|
381
|
-
`
|
|
382
|
-
|
|
394
|
+
`check` uses 0, 1, 2 and 4: 1 when any call site or event has an error (or,
|
|
395
|
+
with `--strict`, a warning) or, with `--strict-suppressions`, a
|
|
396
|
+
`tripl-check-ignore` marker is malformed or unused, 2 for a bad check config or payload file, or a
|
|
397
|
+
config that matches no call (unless `--allow-empty`), and 4 for an unavailable
|
|
398
|
+
instance. `codegen` uses them too: 1 for drift under `--check` (or a plan
|
|
399
|
+
without a configured event type), 2 for a bad check config or template, 4 for
|
|
400
|
+
an unavailable instance; `export` uses 4 the same way.
|
|
383
401
|
|
|
384
402
|
An unreachable instance therefore exits **3** out of `doctor`, not 1 — it
|
|
385
403
|
becomes a finding like everything else doctor reads, which is what makes an exit
|
|
386
|
-
1 out of `doctor` a meaningful bug signal.
|
|
387
|
-
|
|
404
|
+
1 out of `doctor` a meaningful bug signal. `check`, `codegen` and `export` exit
|
|
405
|
+
**4**, so a pipeline can tell an outage from a finding. **Every other command
|
|
406
|
+
exits 1** on an unreachable instance, because none of them turns a failed read
|
|
407
|
+
into a verdict.
|
|
388
408
|
|
|
389
409
|
`doctor` and `status` put exactly one JSON document on stdout, and so does every
|
|
390
410
|
other command except `watch` — but only when the command completes: a write the API
|
|
@@ -464,3 +484,9 @@ uv run --group dev mypy src
|
|
|
464
484
|
than from the published release, so a change here is picked up by
|
|
465
485
|
`cd mcp-server && uv sync` without any install step — and both suites test the
|
|
466
486
|
same source. Run **both** after touching `client.py`.
|
|
487
|
+
|
|
488
|
+
Use `tripl reproduce` to compare synthetic app-test captures from healthy,
|
|
489
|
+
suspect and candidate builds for a tracking incident.
|
|
490
|
+
Create each capture with `tripl journey-capture`.
|
|
491
|
+
|
|
492
|
+
Use `tripl compatibility preview` to compile a bounded historical check of an event rename on a plan branch. After review and merge, `tripl compatibility model` emits the reusable ClickHouse SELECT from the main event.
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
# Reproduce a missing purchase
|
|
2
|
+
|
|
3
|
+
From this directory, using a development install of the Tripl CLI and an empty output directory:
|
|
4
|
+
|
|
5
|
+
```sh
|
|
6
|
+
captures=$(mktemp -d)
|
|
7
|
+
for build in healthy suspect fixed; do
|
|
8
|
+
tripl journey-capture --journey checkout --fixture synthetic-order-v1 \
|
|
9
|
+
--build "$build" --output "$captures/$build.json" --allow-event purchase \
|
|
10
|
+
-- python3 checkout.py "$build" || exit 1
|
|
11
|
+
done
|
|
12
|
+
|
|
13
|
+
tripl reproduce --event purchase --healthy "$captures/healthy.json" \
|
|
14
|
+
--suspect "$captures/suspect.json"
|
|
15
|
+
|
|
16
|
+
tripl reproduce --event purchase --healthy "$captures/healthy.json" \
|
|
17
|
+
--suspect "$captures/suspect.json" --candidate "$captures/fixed.json"
|
|
18
|
+
```
|
|
19
|
+
|
|
20
|
+
The first comparison exits 3 when it reproduces the regression. The second exits 0 when the candidate restores the expected count.
|
|
21
|
+
|
|
22
|
+
For an application pilot, run the capture step inside each build's CI job with its immutable build identifier. Substitute the team's existing deterministic checkout test for the example. Have the test assert successful checkout and write a JSON array of observed event names to the file named by `TRIPL_JOURNEY_EVENTS`. Only explicitly allowlisted event names enter the capture. The adapter runs the command twice with separate output files and a five-minute timeout per attempt. Use a synthetic account and reset the fixture between attempts. Upload the resulting JSON as a CI artifact for the incident comparison.
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
"""Synthetic redirect checkout used by the incident reproduction walkthrough."""
|
|
2
|
+
|
|
3
|
+
import json
|
|
4
|
+
import os
|
|
5
|
+
import sys
|
|
6
|
+
from pathlib import Path
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
def checkout(build: str) -> tuple[str, list[str]]:
|
|
10
|
+
events = ["checkout_started"]
|
|
11
|
+
order = {"state": "pending"}
|
|
12
|
+
# In the suspect revision, returning from the payment app fires the
|
|
13
|
+
# redirect callback but drops the analytics listener during remount.
|
|
14
|
+
listeners = [] if build == "suspect" else [events.append]
|
|
15
|
+
order["state"] = "paid"
|
|
16
|
+
for notify in listeners:
|
|
17
|
+
notify("purchase")
|
|
18
|
+
return order["state"], events
|
|
19
|
+
|
|
20
|
+
|
|
21
|
+
if __name__ == "__main__":
|
|
22
|
+
build = sys.argv[1]
|
|
23
|
+
if build not in {"healthy", "suspect", "fixed"}:
|
|
24
|
+
raise SystemExit("expected healthy, suspect or fixed")
|
|
25
|
+
state, events = checkout(build)
|
|
26
|
+
if state != "paid":
|
|
27
|
+
raise SystemExit("checkout did not finish")
|
|
28
|
+
Path(os.environ["TRIPL_JOURNEY_EVENTS"]).write_text(json.dumps(events))
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
{
|
|
2
|
+
"table": "analytics.events",
|
|
3
|
+
"event_column": "name",
|
|
4
|
+
"platform_column": "platform",
|
|
5
|
+
"build_column": "build",
|
|
6
|
+
"time_column": "ts",
|
|
7
|
+
"dedup_column": "order_id",
|
|
8
|
+
"rules": [
|
|
9
|
+
{"event": "checkout_success", "platform": "ios", "min_build": 1, "max_build": 25},
|
|
10
|
+
{"event": "order_completed", "platform": "ios", "min_build": 25, "max_build": 9999},
|
|
11
|
+
{"event": "checkout_success", "platform": "android", "min_build": 1, "max_build": 9999}
|
|
12
|
+
]
|
|
13
|
+
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
[project]
|
|
2
2
|
name = "tripl"
|
|
3
3
|
# One version for the service, this CLI and tripl-mcp; bin/release.sh writes it.
|
|
4
|
-
version = "0.3.
|
|
4
|
+
version = "0.3.4"
|
|
5
5
|
description = "Command-line client for tripl: instance diagnostics and live monitoring, tracking-plan reads, code checks and codegen against the plan, team notes, and self-hosted install and upgrade"
|
|
6
6
|
readme = "README.md"
|
|
7
7
|
requires-python = ">=3.12"
|
|
@@ -47,12 +47,14 @@ from tripl_cli.api import (
|
|
|
47
47
|
auth,
|
|
48
48
|
branches,
|
|
49
49
|
chart_annotations,
|
|
50
|
+
check_runs,
|
|
50
51
|
data_sources,
|
|
51
52
|
docs,
|
|
52
53
|
event_types,
|
|
53
54
|
events,
|
|
54
55
|
monitoring,
|
|
55
56
|
plan_export,
|
|
57
|
+
plan_revisions,
|
|
56
58
|
plan_validation,
|
|
57
59
|
projects,
|
|
58
60
|
scans,
|
|
@@ -70,6 +72,7 @@ __all__ = [
|
|
|
70
72
|
"auth",
|
|
71
73
|
"branches",
|
|
72
74
|
"chart_annotations",
|
|
75
|
+
"check_runs",
|
|
73
76
|
"data_sources",
|
|
74
77
|
"docs",
|
|
75
78
|
"event_types",
|
|
@@ -78,6 +81,7 @@ __all__ = [
|
|
|
78
81
|
"page_items",
|
|
79
82
|
"page_total",
|
|
80
83
|
"plan_export",
|
|
84
|
+
"plan_revisions",
|
|
81
85
|
"plan_validation",
|
|
82
86
|
"projects",
|
|
83
87
|
"scans",
|
|
@@ -59,7 +59,7 @@ def get_diff(slug: str, branch_id: str) -> ApiRequest:
|
|
|
59
59
|
"""Answers ``{behind_base, entries, summary}``. No CLI verb reads it yet.
|
|
60
60
|
|
|
61
61
|
``tripl plan`` does not expose it: that payload is not a list, so it does
|
|
62
|
-
not fit the one document shape the
|
|
62
|
+
not fit the one document shape the eight read verbs share, and
|
|
63
63
|
``behind_base`` is too load-bearing to smuggle into an ``items`` array.
|
|
64
64
|
``tripl-mcp``'s ``get_branch_diff`` calls this.
|
|
65
65
|
"""
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
"""Uploading a ``tripl check`` run (``tripl check --upload``).
|
|
2
|
+
|
|
3
|
+
A WRITE, unlike validation: it records the run in tripl. A ``write`` key of a
|
|
4
|
+
project editor may send it, and so may the narrow ``check_upload`` key a CI job
|
|
5
|
+
holds (``tk_c_``), which reads like a ``read`` key and may write nothing else.
|
|
6
|
+
A run on the repository's default branch becomes what "used in code" shows on
|
|
7
|
+
each event; any other run is kept as a summary for the history.
|
|
8
|
+
"""
|
|
9
|
+
|
|
10
|
+
from __future__ import annotations
|
|
11
|
+
|
|
12
|
+
from collections.abc import Mapping
|
|
13
|
+
from typing import Any
|
|
14
|
+
|
|
15
|
+
from tripl_cli.api.request import ApiRequest
|
|
16
|
+
|
|
17
|
+
UPLOAD = "/projects/{slug}/check-runs"
|
|
18
|
+
|
|
19
|
+
ENDPOINTS: tuple[tuple[str, str], ...] = (("post", UPLOAD),)
|
|
20
|
+
|
|
21
|
+
# The route's own cap on the calls of one run.
|
|
22
|
+
MAX_CALLS = 5000
|
|
23
|
+
|
|
24
|
+
# The route's per-call bounds (``CheckRunCallIn``, ``CheckRunFinding``). The
|
|
25
|
+
# CLI cuts a longer value rather than have one call fail the whole upload.
|
|
26
|
+
PATH_MAX_LENGTH = 1000
|
|
27
|
+
EVENT_TYPE_MAX_LENGTH = 100
|
|
28
|
+
NAME_MAX_LENGTH = 500
|
|
29
|
+
MESSAGE_MAX_LENGTH = 2000
|
|
30
|
+
FIELD_MAX_LENGTH = 255
|
|
31
|
+
CODE_MAX_LENGTH = 100
|
|
32
|
+
MAX_FINDINGS_PER_CALL = 50
|
|
33
|
+
# Of the run itself.
|
|
34
|
+
REPOSITORY_MAX_LENGTH = 255
|
|
35
|
+
REF_MAX_LENGTH = 255
|
|
36
|
+
CHECK_ROOT_MAX_LENGTH = 1000
|
|
37
|
+
URL_MAX_LENGTH = 2000
|
|
38
|
+
|
|
39
|
+
|
|
40
|
+
def upload(slug: str, run: Mapping[str, Any]) -> ApiRequest:
|
|
41
|
+
"""One run: ``repository``, ``check_root``, ``commit_sha``, ``ref``, ``calls``, ...
|
|
42
|
+
|
|
43
|
+
``run["calls"]`` is sent as given, so it must already be at most ``MAX_CALLS``.
|
|
44
|
+
"""
|
|
45
|
+
calls = run.get("calls") or ()
|
|
46
|
+
if len(calls) > MAX_CALLS:
|
|
47
|
+
raise ValueError(f"at most {MAX_CALLS} calls per check run, got {len(calls)}")
|
|
48
|
+
return ApiRequest("POST", UPLOAD.format(slug=slug), json_body=dict(run))
|
|
@@ -18,12 +18,15 @@ from tripl_cli.api import (
|
|
|
18
18
|
auth,
|
|
19
19
|
branches,
|
|
20
20
|
chart_annotations,
|
|
21
|
+
check_runs,
|
|
21
22
|
data_sources,
|
|
22
23
|
docs,
|
|
23
24
|
event_types,
|
|
24
25
|
events,
|
|
26
|
+
meta_fields,
|
|
25
27
|
monitoring,
|
|
26
28
|
plan_export,
|
|
29
|
+
plan_revisions,
|
|
27
30
|
plan_validation,
|
|
28
31
|
projects,
|
|
29
32
|
scans,
|
|
@@ -35,12 +38,15 @@ SHARED_ENDPOINTS: dict[str, tuple[tuple[str, str], ...]] = {
|
|
|
35
38
|
"auth": auth.ENDPOINTS,
|
|
36
39
|
"branches": branches.ENDPOINTS,
|
|
37
40
|
"chart_annotations": chart_annotations.ENDPOINTS,
|
|
41
|
+
"check_runs": check_runs.ENDPOINTS,
|
|
38
42
|
"data_sources": data_sources.ENDPOINTS,
|
|
39
43
|
"docs": docs.ENDPOINTS,
|
|
40
44
|
"event_types": event_types.ENDPOINTS,
|
|
41
45
|
"events": events.ENDPOINTS,
|
|
46
|
+
"meta_fields": meta_fields.ENDPOINTS,
|
|
42
47
|
"monitoring": monitoring.ENDPOINTS,
|
|
43
48
|
"plan_export": plan_export.ENDPOINTS,
|
|
49
|
+
"plan_revisions": plan_revisions.ENDPOINTS,
|
|
44
50
|
"plan_validation": plan_validation.ENDPOINTS,
|
|
45
51
|
"projects": projects.ENDPOINTS,
|
|
46
52
|
"scans": scans.ENDPOINTS,
|
|
@@ -17,6 +17,7 @@ from tripl_cli.api.request import ApiRequest
|
|
|
17
17
|
LIST = "/projects/{slug}/events"
|
|
18
18
|
DETAIL = "/projects/{slug}/events/{event_id}"
|
|
19
19
|
PROPERTIES = "/projects/{slug}/events/{event_id}/properties"
|
|
20
|
+
WAREHOUSE_SQL = "/projects/{slug}/events/{event_id}/warehouse-sql"
|
|
20
21
|
|
|
21
22
|
ENDPOINTS: tuple[tuple[str, str], ...] = (
|
|
22
23
|
("get", LIST),
|
|
@@ -24,6 +25,7 @@ ENDPOINTS: tuple[tuple[str, str], ...] = (
|
|
|
24
25
|
("post", LIST),
|
|
25
26
|
("patch", DETAIL),
|
|
26
27
|
("get", PROPERTIES),
|
|
28
|
+
("get", WAREHOUSE_SQL),
|
|
27
29
|
)
|
|
28
30
|
|
|
29
31
|
# EventStatus, verbatim from the OpenAPI document. Spelled here rather than in
|
|
@@ -134,6 +136,17 @@ def get_event_properties(slug: str, event_id: str, *, branch: str | None = None)
|
|
|
134
136
|
)
|
|
135
137
|
|
|
136
138
|
|
|
139
|
+
def get_warehouse_sql(slug: str, event_id: str, *, branch: str | None = None) -> ApiRequest:
|
|
140
|
+
"""A query selecting the event's rows from the warehouse, derived from its scan.
|
|
141
|
+
|
|
142
|
+
``{sql, dialect, scan_config_id, scan_config_name, exact, notes, reason}``;
|
|
143
|
+
built on request and never run.
|
|
144
|
+
"""
|
|
145
|
+
return ApiRequest(
|
|
146
|
+
"GET", WAREHOUSE_SQL.format(slug=slug, event_id=event_id), params={"branch": branch}
|
|
147
|
+
)
|
|
148
|
+
|
|
149
|
+
|
|
137
150
|
def create_event(slug: str, body: Any, *, branch: str | None = None) -> ApiRequest:
|
|
138
151
|
return ApiRequest("POST", LIST.format(slug=slug), params={"branch": branch}, json_body=body)
|
|
139
152
|
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
"""Branch-scoped catalog metadata definitions."""
|
|
2
|
+
|
|
3
|
+
from tripl_cli.api.request import ApiRequest
|
|
4
|
+
|
|
5
|
+
LIST = "/projects/{slug}/meta-fields"
|
|
6
|
+
ENDPOINTS = (("get", LIST),)
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
def list_fields(slug: str, branch: str) -> ApiRequest:
|
|
10
|
+
return ApiRequest("GET", LIST.format(slug=slug), params={"branch": branch})
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
"""Plan revisions: the stored copies of a project's whole plan.
|
|
2
|
+
|
|
3
|
+
Only the listing is built here. Taking a revision, reverting to one and reading
|
|
4
|
+
one's full payload stay in the tripl UI, like the branch transitions
|
|
5
|
+
``api/branches.py`` leaves out.
|
|
6
|
+
|
|
7
|
+
The listing covers the whole project and has no ``?branch=``: a revision is a
|
|
8
|
+
fixed copy, not a view of a plan that moves. A row made for a plan branch (its
|
|
9
|
+
merge base, or the merge itself) names that branch in ``branch_id``.
|
|
10
|
+
"""
|
|
11
|
+
|
|
12
|
+
from __future__ import annotations
|
|
13
|
+
|
|
14
|
+
from tripl_cli.api.request import ApiRequest
|
|
15
|
+
|
|
16
|
+
LIST = "/projects/{slug}/revisions"
|
|
17
|
+
|
|
18
|
+
ENDPOINTS: tuple[tuple[str, str], ...] = (("get", LIST),)
|
|
19
|
+
|
|
20
|
+
# The route's own bounds: `limit` is Query(ge=1, le=200) with a server default
|
|
21
|
+
# of 50. Pinned to the OpenAPI document by the contract test.
|
|
22
|
+
LIMIT_DEFAULT = 50
|
|
23
|
+
LIMIT_MAX = 200
|
|
24
|
+
|
|
25
|
+
|
|
26
|
+
def list_revisions(slug: str, *, offset: int | None = None, limit: int | None = None) -> ApiRequest:
|
|
27
|
+
"""Paged, newest first: answers ``{items, total}``.
|
|
28
|
+
|
|
29
|
+
Each item is a summary (id, created_at, kind, summary, branch_id and
|
|
30
|
+
entity_counts) without the stored plan itself.
|
|
31
|
+
"""
|
|
32
|
+
return ApiRequest("GET", LIST.format(slug=slug), params={"offset": offset, "limit": limit})
|
|
@@ -5,7 +5,9 @@ included, may call it. It is still a POST because a batch of up to
|
|
|
5
5
|
``MAX_ITEMS`` items does not fit in a query string.
|
|
6
6
|
|
|
7
7
|
``?branch=`` follows the rule every plan read follows (see ``api/branches.py``):
|
|
8
|
-
omitted means the live main plan.
|
|
8
|
+
omitted means the live main plan. ``?revision=`` names a stored plan revision
|
|
9
|
+
to validate against instead (never with ``branch``); the answer's ``plan`` then
|
|
10
|
+
says which revision judged the calls (``answering_plan``).
|
|
9
11
|
"""
|
|
10
12
|
|
|
11
13
|
from __future__ import annotations
|
|
@@ -40,6 +42,7 @@ def validate(
|
|
|
40
42
|
items: Sequence[Mapping[str, Any]],
|
|
41
43
|
*,
|
|
42
44
|
branch: str | None = None,
|
|
45
|
+
revision: str | None = None,
|
|
43
46
|
strict: bool = False,
|
|
44
47
|
) -> ApiRequest:
|
|
45
48
|
"""One batch. ``items`` is sent as given, so it must already be at most ``MAX_ITEMS``.
|
|
@@ -55,7 +58,7 @@ def validate(
|
|
|
55
58
|
return ApiRequest(
|
|
56
59
|
"POST",
|
|
57
60
|
VALIDATE.format(slug=slug),
|
|
58
|
-
params={"branch": branch},
|
|
61
|
+
params={"branch": branch, "revision": revision},
|
|
59
62
|
json_body=body,
|
|
60
63
|
)
|
|
61
64
|
|
|
@@ -67,6 +70,16 @@ def batches[T](items: Sequence[T], size: int = MAX_ITEMS) -> list[Sequence[T]]:
|
|
|
67
70
|
return [items[start : start + size] for start in range(0, len(items), size)]
|
|
68
71
|
|
|
69
72
|
|
|
73
|
+
def answering_plan(payload: Any) -> JsonDict:
|
|
74
|
+
"""The response's ``plan``: ``revision``, ``plan_hash``, ``created_at``; ``{}`` when absent.
|
|
75
|
+
|
|
76
|
+
Absent means an instance older than the ``revision`` parameter, which
|
|
77
|
+
ignored it and judged the calls by the live plan.
|
|
78
|
+
"""
|
|
79
|
+
plan = payload.get("plan") if isinstance(payload, dict) else None
|
|
80
|
+
return plan if isinstance(plan, dict) else {}
|
|
81
|
+
|
|
82
|
+
|
|
70
83
|
def verdicts(payload: Any) -> JsonList:
|
|
71
84
|
"""The per-item verdicts of one response, in the order the route answered them."""
|
|
72
85
|
return page_items(payload)
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
"""``tripl check``: static and payload validation against the tracking plan (#261).
|
|
2
|
+
|
|
3
|
+
Layers, each importable without the ones after it:
|
|
4
|
+
|
|
5
|
+
``yamlish`` the YAML subset ``.tripl/check.yml`` is read with (no dependency).
|
|
6
|
+
``config`` the config model: per event type, how its calls look.
|
|
7
|
+
``presets`` Segment, Amplitude and Snowplow call specs, in the config's own vocabulary.
|
|
8
|
+
``lexer`` one tokenizer per language family (strings, interpolation, comments).
|
|
9
|
+
``calls`` call sites and Objective-C message sends out of a token stream.
|
|
10
|
+
``symbols`` enum raw values, string constants, string-returning functions.
|
|
11
|
+
``signatures`` a declaration's parameters, and whether one with no body declares.
|
|
12
|
+
``scopes`` named functions, their parameters and bodies (``--list``'s hints).
|
|
13
|
+
``values`` an argument's tokens -> a known string, a choice, a dict, or dynamic.
|
|
14
|
+
``lint`` the opt-in checks of names and keys that need no plan (``lint:``).
|
|
15
|
+
``scan`` files -> call sites -> validation items (static mode).
|
|
16
|
+
``inventory`` the same scan, kept in full for ``--list``: what was read, and why not.
|
|
17
|
+
``payloads`` captured events -> validation items (payload mode).
|
|
18
|
+
``validate`` batching to ``POST /plan/validate`` and mapping verdicts back.
|
|
19
|
+
``render`` the human listing and SARIF 2.1.0; ``--json`` lives in ``tripl_cli.report``.
|
|
20
|
+
``listing`` ``--list``'s text: what each call read, why a value was not, what to configure.
|
|
21
|
+
|
|
22
|
+
Nothing before ``validate`` touches the network.
|
|
23
|
+
"""
|