diff --git a/docs/reports/leo-working-state-20260709/current-truth-index.md b/docs/reports/leo-working-state-20260709/current-truth-index.md index 9540d41..81b80a4 100644 --- a/docs/reports/leo-working-state-20260709/current-truth-index.md +++ b/docs/reports/leo-working-state-20260709/current-truth-index.md @@ -23,6 +23,7 @@ Use this file before making status claims. Prefer fresh VPS/GCP readbacks when c - Live VPS handler direct-claim suite score: `docs/reports/leo-working-state-20260709/telegram-handler-direct-claim-suite-score-current.md` - Live VPS handler direct-claim suite review: `docs/reports/leo-working-state-20260709/telegram-handler-direct-claim-suite-review-current.md` - Telegram-visible direct-claim authorization packet, ready-to-request but not sent: `docs/reports/leo-working-state-20260709/telegram-visible-direct-claim-authorization-packet-current.md` +- Telegram-visible direct-claim capture receipt, currently awaiting capture: `docs/reports/leo-working-state-20260709/telegram-visible-direct-claim-capture-receipt-current.md` - Telegram-visible direct-claim pre-send preflight, local packet checks pass but current shell cannot SSH to VPS: `docs/reports/leo-working-state-20260709/telegram-visible-direct-claim-preflight-current.md` - Telegram-visible direct-claim full-access remote readback command: `docs/reports/leo-working-state-20260709/telegram-visible-direct-claim-remote-readback-command-current.sh` - Argus public KB state probe, read-only HTTP diagnostics: `docs/reports/leo-working-state-20260709/argus-kb-state-current.md` @@ -133,6 +134,7 @@ Use this file before making status claims. Prefer fresh VPS/GCP readbacks when c - The broader sandbox-first Cory-style benchmark has a full-catalog mixed-evidence score: real retained live Telegram evidence for `OE-01` through `OE-05`, sandbox fixture replies for `CS-01` through `CS-09`, and no-context direct-claim expected-answer/follow-up fixtures for `DC-01` through `DC-06`, `20/20` passing. This is not a live Telegram run for the CS/DC prompts. - The live VPS GatewayRunner direct-claim handler suite for exact `DC-01` through `DC-06` passed again after deploy SHA `7ab563e1aebe08913e72781e4e16a2b2883c5230`: `6/6` runtime replies, strict score `6/6`, no Telegram post, no live profile write, no production DB apply, unchanged DB counts (`public.claims=1837`, `public.sources=4145`, `public.claim_edges=4916`, `public.claim_evidence=4670`, `kb_stage.kb_proposals=26` before and after), temp profile removed, and `leoclean-gateway.service` stayed active/running during the harness with `MainPID=1908033`, `NRestarts=0`, `ExecMainStartTimestamp=Fri 2026-07-10 01:04:22 UTC`. - The Telegram-visible direct-claim benchmark is now executable as an exact authorization packet, not yet run: target `Leo` group `-5146042086`, raw no-context messages `DC-01` through `DC-06`, expected proof paths, before/after DB/service readbacks, scorer output, and final screenshot/accessibility proof are retained in `telegram-visible-direct-claim-authorization-packet-current.md`; `telegram_visible_messages_sent=false`. +- The Telegram-visible direct-claim capture receipt assembler is retained and currently `status=awaiting_capture`; it will not emit a passing receipt until the exact operator authorization text, exact six DC messages, nonempty Telegram-visible Leo replies, DB before/after counts, service readback, final screenshot/accessibility proof, and `6/6` direct-claim score are present. - The Telegram-visible direct-claim pre-send preflight harness now verifies the authorization packet and can consume a supplied VPS readback JSON payload. Current local packet checks pass, but this current shell cannot open SSH to `77.42.65.182:22` (`Operation not permitted`), so the retained preflight artifact is `status=fail` until a full-access VPS readback is supplied. The exact copy-pasteable full-access command is retained in `telegram-visible-direct-claim-remote-readback-command-current.sh` with SHA256 `741b9ee14548122cc5e15009f3bbbbfddd4389a1452099265f80f367cbe467ec`; no Telegram messages were sent and no DB apply ran. - The public Argus KB diagnostics HTTP probe passes from live `curl` payloads captured at `2026-07-10T02:47:53Z`: `3` approved proposals are visible (`14fa5ecc`, `ac036c9d`, `a64df080`), all are `approved_needs_apply_payload`, `worker_applyable_count=0`, and the endpoint is read-only. This supports Leo's expected answer that the approved KB work is not yet directly applyable/canonical, but it is not Docker/Postgres row-count or gateway-service proof. - The highest-risk direct-claim cases are now green at handler level: `DC-02` recognizes approved Helmer staging row `a64df080-8502-42e2-98f4-9bbdecb8da73` as approved/unapplied, `DC-03` says the decision-matrix path is not shipped while matrix tables are absent, `DC-04` avoids a single-cause document pointer diagnosis, `DC-05` separates staging demo from authorized canonical apply, and `DC-06` separates `SOUL.md` runtime edits from canonical DB identity. diff --git a/docs/reports/leo-working-state-20260709/telegram-visible-direct-claim-authorization-packet-current.json b/docs/reports/leo-working-state-20260709/telegram-visible-direct-claim-authorization-packet-current.json index 066360a..0d956a2 100644 --- a/docs/reports/leo-working-state-20260709/telegram-visible-direct-claim-authorization-packet-current.json +++ b/docs/reports/leo-working-state-20260709/telegram-visible-direct-claim-authorization-packet-current.json @@ -127,6 +127,9 @@ } ], "expected_proof_paths_after_authorized_run": { + "capture_receipt_json": "docs/reports/leo-working-state-20260709/telegram-visible-direct-claim-capture-receipt-current.json", + "capture_receipt_markdown": "docs/reports/leo-working-state-20260709/telegram-visible-direct-claim-capture-receipt-current.md", + "capture_results_json": "docs/reports/leo-working-state-20260709/telegram-visible-direct-claim-capture-results-current.json", "db_before_after": "outputs/telegram-visible-direct-claim-suite-20260710/telegram-visible-direct-claim-suite-db-before-after.json", "final_accessibility": "outputs/telegram-visible-direct-claim-suite-20260710/telegram-visible-direct-claim-suite-final-accessibility.txt", "final_screenshot": "outputs/telegram-visible-direct-claim-suite-20260710/telegram-visible-direct-claim-suite-final.png", @@ -136,7 +139,7 @@ "service_readback": "outputs/telegram-visible-direct-claim-suite-20260710/telegram-visible-direct-claim-suite-service-readback.txt" }, "explicit_operator_authorization_text": "I authorize a Telegram-visible read-only direct-claim benchmark in the Leo group `Leo` (`-5146042086`) using exactly the six raw messages DC-01 through DC-06 listed in `telegram-visible-direct-claim-authorization-packet-current.json`. Capture before/after DB counts, Telegram-visible replies, scorer output, final screenshot/accessibility proof, and service readback. Do not run production DB apply, do not edit SOUL.md, do not post any extra messages beyond those six benchmark prompts unless separately authorized.", - "generated_at_utc": "2026-07-10T02:29:58.153246+00:00", + "generated_at_utc": "2026-07-10T03:01:26.939311+00:00", "mode": "telegram_visible_direct_claim_authorization_packet_not_sent", "mutates_db": false, "next_non_user_action_after_authorization": [ @@ -144,9 +147,9 @@ "Send exactly the six raw DC-01..DC-06 messages to Telegram group Leo.", "Capture each Telegram-visible Leo reply plus a final screenshot/accessibility readback.", "Read DB counts and service state after sending.", - "Score the retained replies and update the current truth index." + "Assemble the retained capture receipt and score it before updating the current truth index." ], - "packet_generation_git_sha": "262ddb9e0d5b3f8a00b4529dcd00f03317a8e90b", + "packet_generation_git_sha": "97755068d3fd1a97d9da11be3a64f22b751d8c41", "production_apply_authorization_present": false, "production_apply_executed": false, "ready_to_request_authorization": true, diff --git a/docs/reports/leo-working-state-20260709/telegram-visible-direct-claim-authorization-packet-current.md b/docs/reports/leo-working-state-20260709/telegram-visible-direct-claim-authorization-packet-current.md index 997b34f..147a3a5 100644 --- a/docs/reports/leo-working-state-20260709/telegram-visible-direct-claim-authorization-packet-current.md +++ b/docs/reports/leo-working-state-20260709/telegram-visible-direct-claim-authorization-packet-current.md @@ -1,6 +1,6 @@ # Telegram-Visible Direct-Claim Authorization Packet -Generated UTC: `2026-07-10T02:29:58.153246+00:00` +Generated UTC: `2026-07-10T03:01:26.939311+00:00` Mode: `telegram_visible_direct_claim_authorization_packet_not_sent` Ready to request authorization: `True` Authorization gate status: `ready_to_request_explicit_authorization` @@ -78,7 +78,7 @@ To run the Telegram-visible DC benchmark, reply with the exact authorization tex - Send exactly the six raw DC-01..DC-06 messages to Telegram group Leo. - Capture each Telegram-visible Leo reply plus a final screenshot/accessibility readback. - Read DB counts and service state after sending. -- Score the retained replies and update the current truth index. +- Assemble the retained capture receipt and score it before updating the current truth index. ## Do Not Run Without diff --git a/docs/reports/leo-working-state-20260709/telegram-visible-direct-claim-capture-receipt-current.json b/docs/reports/leo-working-state-20260709/telegram-visible-direct-claim-capture-receipt-current.json new file mode 100644 index 0000000..41bb8d5 --- /dev/null +++ b/docs/reports/leo-working-state-20260709/telegram-visible-direct-claim-capture-receipt-current.json @@ -0,0 +1,124 @@ +{ + "capture_present": false, + "capture_template": { + "capture_source": { + "captured_at_utc": "", + "captured_by": "", + "chat_id": "-5146042086", + "chat_label": "Leo", + "final_accessibility": "", + "final_screenshot": "", + "platform": "telegram" + }, + "db_before_after": { + "after": {}, + "before": {}, + "db_counts_changed": null + }, + "messages": [ + { + "prompt_id": "DC-01", + "reply": "", + "reply_at_utc": "", + "reply_message_id": "", + "sent_at_utc": "", + "sent_text": "Did we actually update the knowledge base, or is it still just proposals?", + "telegram_message_id": "" + }, + { + "prompt_id": "DC-02", + "reply": "", + "reply_at_utc": "", + "reply_message_id": "", + "sent_at_utc": "", + "sent_text": "Is Helmer's 7 Powers in Leo now?", + "telegram_message_id": "" + }, + { + "prompt_id": "DC-03", + "reply": "", + "reply_at_utc": "", + "reply_message_id": "", + "sent_at_utc": "", + "sent_text": "Did the decision matrix approve this already?", + "telegram_message_id": "" + }, + { + "prompt_id": "DC-04", + "reply": "", + "reply_at_utc": "", + "reply_message_id": "", + "sent_at_utc": "", + "sent_text": "Are the pending proposals stuck because the documents are not pointed at the right source rows?", + "telegram_message_id": "" + }, + { + "prompt_id": "DC-05", + "reply": "", + "reply_at_utc": "", + "reply_message_id": "", + "sent_at_utc": "", + "sent_text": "Can I demo that Leo changes the KB?", + "telegram_message_id": "" + }, + { + "prompt_id": "DC-06", + "reply": "", + "reply_at_utc": "", + "reply_message_id": "", + "sent_at_utc": "", + "sent_text": "If we changed SOUL.md, did we change Leo's canonical identity?", + "telegram_message_id": "" + } + ], + "operator_authorization_text": "I authorize a Telegram-visible read-only direct-claim benchmark in the Leo group `Leo` (`-5146042086`) using exactly the six raw messages DC-01 through DC-06 listed in `telegram-visible-direct-claim-authorization-packet-current.json`. Capture before/after DB counts, Telegram-visible replies, scorer output, final screenshot/accessibility proof, and service readback. Do not run production DB apply, do not edit SOUL.md, do not post any extra messages beyond those six benchmark prompts unless separately authorized.", + "service_readback": { + "after": {}, + "before": {} + } + }, + "checks": { + "authorization_text_matches": false, + "capture_complete_for_scoring": false, + "capture_present": false, + "db_before_after_present": false, + "empty_reply_prompt_ids": [ + "DC-01", + "DC-02", + "DC-03", + "DC-04", + "DC-05", + "DC-06" + ], + "final_visual_proof_present": false, + "message_ids_exact": false, + "missing_prompt_ids": [ + "DC-01", + "DC-02", + "DC-03", + "DC-04", + "DC-05", + "DC-06" + ], + "replies_nonempty": false, + "score_passes": false, + "sent_text_exact": false, + "service_readback_present": false, + "target_matches_packet": false, + "text_mismatch_prompt_ids": [], + "unexpected_prompt_ids": [] + }, + "claim_ceiling": "This receipt validates retained Telegram-visible capture evidence only. It does not send Telegram messages, does not run production apply, and does not prove canonical DB mutation. A pass requires exact DC-01..DC-06 messages, matching operator authorization, nonempty visible replies, DB/service readbacks, visual proof, and a 6/6 direct-claim score.", + "generated_at_utc": "2026-07-10T03:01:26.898794+00:00", + "mode": "telegram_visible_direct_claim_capture_receipt", + "mutates_db": false, + "packet_path": "docs/reports/leo-working-state-20260709/telegram-visible-direct-claim-authorization-packet-current.json", + "production_apply_executed": false, + "receipt_ready": false, + "results": [], + "results_out": "docs/reports/leo-working-state-20260709/telegram-visible-direct-claim-capture-results-current.json", + "score": null, + "source_capture_path": "", + "status": "awaiting_capture", + "telegram_visible_messages_sent": false +} diff --git a/docs/reports/leo-working-state-20260709/telegram-visible-direct-claim-capture-receipt-current.md b/docs/reports/leo-working-state-20260709/telegram-visible-direct-claim-capture-receipt-current.md new file mode 100644 index 0000000..b916ba7 --- /dev/null +++ b/docs/reports/leo-working-state-20260709/telegram-visible-direct-claim-capture-receipt-current.md @@ -0,0 +1,36 @@ +# Telegram-Visible Direct-Claim Capture Receipt + +Generated UTC: `2026-07-10T03:01:26.898794+00:00` +Mode: `telegram_visible_direct_claim_capture_receipt` +Status: `awaiting_capture` +Receipt ready: `False` +Capture present: `False` +Telegram-visible messages sent: `False` +Production apply executed: `False` +Mutates DB: `False` + +## Checks + +- `authorization_text_matches`: `False` +- `capture_complete_for_scoring`: `False` +- `capture_present`: `False` +- `db_before_after_present`: `False` +- `empty_reply_prompt_ids`: `['DC-01', 'DC-02', 'DC-03', 'DC-04', 'DC-05', 'DC-06']` +- `final_visual_proof_present`: `False` +- `message_ids_exact`: `False` +- `missing_prompt_ids`: `['DC-01', 'DC-02', 'DC-03', 'DC-04', 'DC-05', 'DC-06']` +- `replies_nonempty`: `False` +- `score_passes`: `False` +- `sent_text_exact`: `False` +- `service_readback_present`: `False` +- `target_matches_packet`: `False` +- `text_mismatch_prompt_ids`: `[]` +- `unexpected_prompt_ids`: `[]` + +## Capture Template + +Populate `messages[].reply`, timestamp/id fields, `db_before_after`, `service_readback`, and `capture_source.final_screenshot` / `capture_source.final_accessibility`, then rerun this script with `--capture-json`. + +## Claim Ceiling + +This receipt validates retained Telegram-visible capture evidence only. It does not send Telegram messages, does not run production apply, and does not prove canonical DB mutation. A pass requires exact DC-01..DC-06 messages, matching operator authorization, nonempty visible replies, DB/service readbacks, visual proof, and a 6/6 direct-claim score. diff --git a/docs/reports/leo-working-state-20260709/working-leo-current-state-20260709.md b/docs/reports/leo-working-state-20260709/working-leo-current-state-20260709.md index f44982d..6fb6ef1 100644 --- a/docs/reports/leo-working-state-20260709/working-leo-current-state-20260709.md +++ b/docs/reports/leo-working-state-20260709/working-leo-current-state-20260709.md @@ -53,9 +53,14 @@ A working Leo, for Cory/m3taversal's current expectation, is a Telegram-facing a - Telegram-visible direct-claim benchmark is now ready to request with exact scope, but not run: - target is Telegram group `Leo` (`-5146042086`) - exact raw no-context messages are `DC-01` through `DC-06` from the benchmark catalog - - required proof after authorization is before/after DB counts, Telegram-visible replies, scorer output, final screenshot/accessibility proof, and service readback + - required proof after authorization is before/after DB counts, Telegram-visible replies, capture receipt, scorer output, final screenshot/accessibility proof, and service readback - artifact: `work/teleo-infra-main/docs/reports/leo-working-state-20260709/telegram-visible-direct-claim-authorization-packet-current.md` - current status remains `telegram_visible_messages_sent=false` +- Telegram-visible direct-claim capture receipt assembler is now retained: + - artifact: `work/teleo-infra-main/docs/reports/leo-working-state-20260709/telegram-visible-direct-claim-capture-receipt-current.md` + - current status is `awaiting_capture` + - receipt readiness requires exact operator authorization text, exact `DC-01` through `DC-06` sent texts, nonempty Telegram-visible replies, DB before/after counts, service readback, final screenshot/accessibility proof, and `6/6` direct-claim score + - the assembler does not send Telegram messages, does not run production apply, and does not prove canonical DB mutation - Telegram-visible direct-claim pre-send preflight harness is now retained: - artifact: `work/teleo-infra-main/docs/reports/leo-working-state-20260709/telegram-visible-direct-claim-preflight-current.md` - full-access remote readback command: `work/teleo-infra-main/docs/reports/leo-working-state-20260709/telegram-visible-direct-claim-remote-readback-command-current.sh` @@ -82,6 +87,7 @@ A working Leo, for Cory/m3taversal's current expectation, is a Telegram-facing a ## What Is Still Not Proven - The no-context direct-claim behavior Cory is likely to use is handler-proven for `DC-01` through `DC-06` on the VPS GatewayRunner path, and an exact Telegram-visible authorization packet is ready. It has still not been sent as a public/group post. +- The Telegram-visible direct-claim capture receipt is not ready because no authorized visible DC capture exists yet. - The Telegram-visible direct-claim pre-send DB/service/deploy readback is not currently proven in this shell because SSH to `77.42.65.182:22` is denied; the preflight can be completed by running `telegram-visible-direct-claim-remote-readback-command-current.sh` from a full-access shell and passing its base64 output back through `--remote-json-base64`. - Old Cory-approved mapped rich proposals are still not fully directly applyable: - `14fa5ecc-ac7a-41c1-807d-a2e85b936617` @@ -227,6 +233,7 @@ A working Leo, for Cory/m3taversal's current expectation, is a Telegram-facing a - Live VPS handler direct-claim suite: `work/teleo-infra-main/docs/reports/leo-working-state-20260709/telegram-handler-direct-claim-suite-current.json` - Live VPS handler direct-claim suite score: `work/teleo-infra-main/docs/reports/leo-working-state-20260709/telegram-handler-direct-claim-suite-score-current.md` - Live VPS handler direct-claim suite review: `work/teleo-infra-main/docs/reports/leo-working-state-20260709/telegram-handler-direct-claim-suite-review-current.md` +- Telegram-visible direct-claim capture receipt: `work/teleo-infra-main/docs/reports/leo-working-state-20260709/telegram-visible-direct-claim-capture-receipt-current.md` - Gateway adapter canary: `outputs/telegram-gateway-canary-20260709/telegram-gateway-canary-current.md` - KB apply plan: `outputs/kb-apply-canary-20260709/kb-apply-canary-plan-current.md` - KB apply execute: `outputs/kb-apply-canary-20260709/kb-apply-canary-execute-current.md` diff --git a/docs/reports/leo-working-state-20260709/working-leo-execution-plan-current.md b/docs/reports/leo-working-state-20260709/working-leo-execution-plan-current.md index 8c9b789..368f89d 100644 --- a/docs/reports/leo-working-state-20260709/working-leo-execution-plan-current.md +++ b/docs/reports/leo-working-state-20260709/working-leo-execution-plan-current.md @@ -1,6 +1,6 @@ # Working Leo Execution Plan - 2026-07-09 -Claim ceiling: VPS Telegram memory/KB audit, full live-safe open-ended Telegram suite, full mixed-evidence Cory-style outcome/direct-claim sandbox benchmark, live VPS GatewayRunner no-context direct-claim suite, Telegram-visible DC authorization packet, Telegram-to-`kb_stage` proposal staging, and strict existing-ID apply are working. The live VPS handler suite for exact `DC-01` through `DC-06` prompts strict-scores `6/6` after the authorized-session-plan deploy and scorer refresh, with no Telegram post, no live profile write, no production DB apply, unchanged DB counts, temp profile cleanup, and unchanged gateway service state during the harness. The Telegram-visible DC suite is exact-scoped and ready to request authorization, but not sent; the new pre-send preflight harness verifies the packet but cannot complete the current shell's SSH deploy/service/DB readback gate without a supplied full-access VPS JSON payload. It now retains a copy-pasteable full-access command script for that payload. Public Argus HTTP diagnostics currently show `3` approved proposals, all `approved_needs_apply_payload`, with `worker_applyable_count=0`, which supports the expected no-overclaim answer but does not prove Docker row counts or systemd state. The full prepared DB packet set is integrated-clone-proven in dependency order: mapped rich base, cross-surface anchor, Rio strategy context, governance/concept schema, and Helmer 7 Powers. A read-only live production preflight baseline now passes `5/5`, an authorized apply operator runbook is generated, an authorized apply session plan maps every apply-window output path with authorization gates, a production apply authorization packet is ready-to-request, the authorization verifier refuses the current apply window because no exact authorization text/operator identity is present, and the receipt assembler refuses final receipt emission because post-apply session artifacts/counts are absent. None of those packets are production-applied or authorized. GCP parity remains pending. +Claim ceiling: VPS Telegram memory/KB audit, full live-safe open-ended Telegram suite, full mixed-evidence Cory-style outcome/direct-claim sandbox benchmark, live VPS GatewayRunner no-context direct-claim suite, Telegram-visible DC authorization packet, Telegram-to-`kb_stage` proposal staging, and strict existing-ID apply are working. The live VPS handler suite for exact `DC-01` through `DC-06` prompts strict-scores `6/6` after the authorized-session-plan deploy and scorer refresh, with no Telegram post, no live profile write, no production DB apply, unchanged DB counts, temp profile cleanup, and unchanged gateway service state during the harness. The Telegram-visible DC suite is exact-scoped and ready to request authorization, but not sent; the new pre-send preflight harness verifies the packet but cannot complete the current shell's SSH deploy/service/DB readback gate without a supplied full-access VPS JSON payload. It now retains a copy-pasteable full-access command script for that payload, and the capture receipt assembler is retained but remains `awaiting_capture` until real visible replies plus DB/service/visual proof are supplied and scored. Public Argus HTTP diagnostics currently show `3` approved proposals, all `approved_needs_apply_payload`, with `worker_applyable_count=0`, which supports the expected no-overclaim answer but does not prove Docker row counts or systemd state. The full prepared DB packet set is integrated-clone-proven in dependency order: mapped rich base, cross-surface anchor, Rio strategy context, governance/concept schema, and Helmer 7 Powers. A read-only live production preflight baseline now passes `5/5`, an authorized apply operator runbook is generated, an authorized apply session plan maps every apply-window output path with authorization gates, a production apply authorization packet is ready-to-request, the authorization verifier refuses the current apply window because no exact authorization text/operator identity is present, and the receipt assembler refuses final receipt emission because post-apply session artifacts/counts are absent. None of those packets are production-applied or authorized. GCP parity remains pending. ## WL-EXEC-01 - VPS Telegram-visible memory + KB audit - Status: `done` @@ -14,7 +14,7 @@ Claim ceiling: VPS Telegram memory/KB audit, full live-safe open-ended Telegram ## WL-EXEC-01B - Cory-style outcome and direct-claim benchmark - Status: `sandbox_fixture_done_live_handler_done_telegram_visible_auth_ready` -- Result: Full mixed-evidence Cory-style benchmark scores `20/20`: `OE-01` through `OE-05` are retained live Telegram read-only replies; `CS-01` through `CS-09` are sandbox expected-answer fixtures covering broader regular-use cases; `DC-01` through `DC-06` are no-context direct-claim expected-answer fixtures requiring the correct Cory-style follow-up action. A live VPS GatewayRunner handler run of the exact `DC-01` through `DC-06` prompts now returns `6/6` replies and strict-scores `6/6` with no Telegram post, no live profile write, no production DB apply, unchanged DB counts, and unchanged service state during the harness. The Telegram-visible DC run now has an exact authorization packet for the raw `DC-01` through `DC-06` group messages, proof paths, scorer command, DB/service readbacks, and screenshot/accessibility capture; it has not been sent. The pre-send preflight harness now exists and local packet checks pass, but the retained current artifact is `status=fail` because this shell cannot SSH to `77.42.65.182:22`; run `telegram-visible-direct-claim-remote-readback-command-current.sh` from a full-access shell, then rerun the preflight with `--remote-json-base64` to unlock the Telegram-visible send gate. The Argus HTTP diagnostics probe passes and shows the currently approved proposals are visible but still not worker-applyable. +- Result: Full mixed-evidence Cory-style benchmark scores `20/20`: `OE-01` through `OE-05` are retained live Telegram read-only replies; `CS-01` through `CS-09` are sandbox expected-answer fixtures covering broader regular-use cases; `DC-01` through `DC-06` are no-context direct-claim expected-answer fixtures requiring the correct Cory-style follow-up action. A live VPS GatewayRunner handler run of the exact `DC-01` through `DC-06` prompts now returns `6/6` replies and strict-scores `6/6` with no Telegram post, no live profile write, no production DB apply, unchanged DB counts, and unchanged service state during the harness. The Telegram-visible DC run now has an exact authorization packet for the raw `DC-01` through `DC-06` group messages, proof paths, scorer command, DB/service readbacks, and screenshot/accessibility capture; it has not been sent. The capture receipt assembler now exists and is `awaiting_capture`, refusing pass until the exact authorized visible replies, DB/service readbacks, screenshot/accessibility proof, and `6/6` score are present. The pre-send preflight harness now exists and local packet checks pass, but the retained current artifact is `status=fail` because this shell cannot SSH to `77.42.65.182:22`; run `telegram-visible-direct-claim-remote-readback-command-current.sh` from a full-access shell, then rerun the preflight with `--remote-json-base64` to unlock the Telegram-visible send gate. The Argus HTTP diagnostics probe passes and shows the currently approved proposals are visible but still not worker-applyable. - Not done condition: Reopen if `DC-02` stops recognizing approved Helmer staging row `a64df080-8502-42e2-98f4-9bbdecb8da73` as approved/unapplied, `DC-03` infers decision-matrix approval while `matrix_voters`, `proposal_votes`, and `proposal_decisions` tables are absent, any direct-claim answer omits the `Next Cory-style follow-up:` line, the handler mutates DB/service state during a read-only suite, or the Telegram-visible DC authorization packet drifts from the raw benchmark catalog. - Evidence: - `/Users/user/Documents/Codex/2026-07-09/019f34eb-d297-72d0-b7e2-b222d5515ab9-load/work/teleo-infra-main/docs/reports/leo-working-state-20260709/working-leo-cory-outcome-sandbox-results-current.md` @@ -22,6 +22,7 @@ Claim ceiling: VPS Telegram memory/KB audit, full live-safe open-ended Telegram - `/Users/user/Documents/Codex/2026-07-09/019f34eb-d297-72d0-b7e2-b222d5515ab9-load/work/teleo-infra-main/docs/reports/leo-working-state-20260709/telegram-handler-direct-claim-suite-review-current.md` - `/Users/user/Documents/Codex/2026-07-09/019f34eb-d297-72d0-b7e2-b222d5515ab9-load/work/teleo-infra-main/docs/reports/leo-working-state-20260709/telegram-handler-direct-claim-suite-score-current.md` - `/Users/user/Documents/Codex/2026-07-09/019f34eb-d297-72d0-b7e2-b222d5515ab9-load/work/teleo-infra-main/docs/reports/leo-working-state-20260709/telegram-visible-direct-claim-authorization-packet-current.md` + - `/Users/user/Documents/Codex/2026-07-09/019f34eb-d297-72d0-b7e2-b222d5515ab9-load/work/teleo-infra-main/docs/reports/leo-working-state-20260709/telegram-visible-direct-claim-capture-receipt-current.md` - `/Users/user/Documents/Codex/2026-07-09/019f34eb-d297-72d0-b7e2-b222d5515ab9-load/work/teleo-infra-main/docs/reports/leo-working-state-20260709/telegram-visible-direct-claim-preflight-current.md` - `/Users/user/Documents/Codex/2026-07-09/019f34eb-d297-72d0-b7e2-b222d5515ab9-load/work/teleo-infra-main/docs/reports/leo-working-state-20260709/telegram-visible-direct-claim-remote-readback-command-current.sh` - `/Users/user/Documents/Codex/2026-07-09/019f34eb-d297-72d0-b7e2-b222d5515ab9-load/work/teleo-infra-main/docs/reports/leo-working-state-20260709/argus-kb-state-current.md` diff --git a/scripts/assemble_telegram_visible_direct_claim_capture_receipt.py b/scripts/assemble_telegram_visible_direct_claim_capture_receipt.py new file mode 100644 index 0000000..981aa1b --- /dev/null +++ b/scripts/assemble_telegram_visible_direct_claim_capture_receipt.py @@ -0,0 +1,349 @@ +#!/usr/bin/env python3 +"""Assemble and score a Telegram-visible direct-claim capture receipt. + +This script does not send Telegram messages and does not mutate the database. +It validates a retained capture from the authorized DC-01..DC-06 Telegram group +run against the authorization packet, emits scorer-ready results, and records a +receipt/status artifact. With no capture JSON it emits an awaiting-capture +template so the required evidence shape is explicit. +""" + +from __future__ import annotations + +import argparse +import json +from datetime import datetime, timezone +from pathlib import Path +from typing import Any + +import working_leo_open_ended_benchmark as benchmark + +REPORT_DIR = Path("docs/reports/leo-working-state-20260709") +DEFAULT_PACKET = REPORT_DIR / "telegram-visible-direct-claim-authorization-packet-current.json" +DEFAULT_OUT = REPORT_DIR / "telegram-visible-direct-claim-capture-receipt-current.json" +DEFAULT_MARKDOWN_OUT = REPORT_DIR / "telegram-visible-direct-claim-capture-receipt-current.md" +DEFAULT_RESULTS_OUT = REPORT_DIR / "telegram-visible-direct-claim-capture-results-current.json" + + +def _load_json(path: Path) -> dict[str, Any]: + return json.loads(path.read_text(encoding="utf-8")) + + +def expected_messages(packet: dict[str, Any]) -> list[dict[str, Any]]: + return [ + { + "prompt_id": item["prompt_id"], + "dimension": item["dimension"], + "sent_text": item["message"], + "required_signals": item.get("required_signals", []), + } + for item in packet.get("exact_messages", []) + ] + + +def blank_capture_template(packet: dict[str, Any]) -> dict[str, Any]: + target = packet.get("target", {}) + return { + "operator_authorization_text": packet.get("explicit_operator_authorization_text", ""), + "capture_source": { + "platform": target.get("platform", "telegram"), + "chat_label": target.get("chat_label", ""), + "chat_id": target.get("chat_id", ""), + "captured_at_utc": "", + "captured_by": "", + "final_screenshot": "", + "final_accessibility": "", + }, + "db_before_after": { + "before": {}, + "after": {}, + "db_counts_changed": None, + }, + "service_readback": { + "before": {}, + "after": {}, + }, + "messages": [ + { + "prompt_id": item["prompt_id"], + "sent_text": item["sent_text"], + "reply": "", + "sent_at_utc": "", + "reply_at_utc": "", + "telegram_message_id": "", + "reply_message_id": "", + } + for item in expected_messages(packet) + ], + } + + +def _present(value: Any) -> bool: + if value is None: + return False + if isinstance(value, str): + return bool(value.strip()) + if isinstance(value, dict | list): + return bool(value) + return True + + +def _capture_messages(capture: dict[str, Any]) -> list[dict[str, Any]]: + messages = capture.get("messages") + return [item for item in messages if isinstance(item, dict)] if isinstance(messages, list) else [] + + +def validate_capture(packet: dict[str, Any], capture: dict[str, Any] | None) -> dict[str, Any]: + expected = expected_messages(packet) + expected_by_id = {item["prompt_id"]: item for item in expected} + expected_ids = [item["prompt_id"] for item in expected] + if capture is None: + return { + "capture_present": False, + "authorization_text_matches": False, + "target_matches_packet": False, + "message_ids_exact": False, + "sent_text_exact": False, + "replies_nonempty": False, + "db_before_after_present": False, + "service_readback_present": False, + "final_visual_proof_present": False, + "capture_complete_for_scoring": False, + "missing_prompt_ids": expected_ids, + "unexpected_prompt_ids": [], + "text_mismatch_prompt_ids": [], + "empty_reply_prompt_ids": expected_ids, + } + + target = packet.get("target", {}) + source = capture.get("capture_source") if isinstance(capture.get("capture_source"), dict) else {} + messages = _capture_messages(capture) + by_id = {str(item.get("prompt_id")): item for item in messages if item.get("prompt_id")} + found_ids = [str(item.get("prompt_id")) for item in messages if item.get("prompt_id")] + missing = [prompt_id for prompt_id in expected_ids if prompt_id not in by_id] + unexpected = [prompt_id for prompt_id in found_ids if prompt_id not in expected_by_id] + text_mismatch = [ + prompt_id + for prompt_id in expected_ids + if prompt_id in by_id and str(by_id[prompt_id].get("sent_text") or "") != expected_by_id[prompt_id]["sent_text"] + ] + empty_replies = [ + prompt_id + for prompt_id in expected_ids + if prompt_id in by_id and not str(by_id[prompt_id].get("reply") or "").strip() + ] + authorization_text = str(capture.get("operator_authorization_text") or "") + target_matches = ( + source.get("platform") == target.get("platform") + and source.get("chat_label") == target.get("chat_label") + and source.get("chat_id") == target.get("chat_id") + ) + db_before_after = capture.get("db_before_after") + service_readback = capture.get("service_readback") + final_visual = _present(source.get("final_screenshot")) and _present(source.get("final_accessibility")) + message_ids_exact = found_ids == expected_ids + sent_text_exact = not text_mismatch and message_ids_exact + replies_nonempty = not empty_replies and message_ids_exact + return { + "capture_present": True, + "authorization_text_matches": authorization_text == packet.get("explicit_operator_authorization_text"), + "target_matches_packet": target_matches, + "message_ids_exact": message_ids_exact, + "sent_text_exact": sent_text_exact, + "replies_nonempty": replies_nonempty, + "db_before_after_present": isinstance(db_before_after, dict) and _present(db_before_after.get("before")) + and _present(db_before_after.get("after")), + "service_readback_present": _present(service_readback), + "final_visual_proof_present": final_visual, + "capture_complete_for_scoring": message_ids_exact and sent_text_exact and replies_nonempty, + "missing_prompt_ids": missing, + "unexpected_prompt_ids": unexpected, + "text_mismatch_prompt_ids": text_mismatch, + "empty_reply_prompt_ids": empty_replies, + } + + +def scorer_results(packet: dict[str, Any], capture: dict[str, Any]) -> list[dict[str, Any]]: + by_id = {str(item.get("prompt_id")): item for item in _capture_messages(capture) if item.get("prompt_id")} + results = [] + for item in expected_messages(packet): + captured = by_id[item["prompt_id"]] + results.append( + { + "prompt_id": item["prompt_id"], + "dimension": item["dimension"], + "prompt": item["sent_text"], + "reply": str(captured.get("reply") or ""), + "ok": True, + "mutates_kb": False, + "evidence_tier": "telegram_visible_capture", + "sent_at_utc": captured.get("sent_at_utc", ""), + "reply_at_utc": captured.get("reply_at_utc", ""), + "telegram_message_id": captured.get("telegram_message_id", ""), + "reply_message_id": captured.get("reply_message_id", ""), + } + ) + return results + + +def score_capture(packet: dict[str, Any], results: list[dict[str, Any]]) -> dict[str, Any]: + catalog = benchmark.prompt_catalog(include_direct_claim_followups=True) + return benchmark.score_result_subset( + results, + catalog=catalog, + expected_prompt_ids=list(packet.get("target", {}).get("expected_prompt_ids", [])), + ) + + +def build_receipt( + packet: dict[str, Any], + capture: dict[str, Any] | None, + *, + source_capture_path: Path | None, + packet_path: Path = DEFAULT_PACKET, + results_out: Path = DEFAULT_RESULTS_OUT, +) -> dict[str, Any]: + checks = validate_capture(packet, capture) + results: list[dict[str, Any]] = [] + score: dict[str, Any] | None = None + if capture is not None and checks["capture_complete_for_scoring"]: + results = scorer_results(packet, capture) + score = score_capture(packet, results) + score_passes = bool(score and score.get("pass") is True) + checks["score_passes"] = score_passes + receipt_ready = ( + checks["capture_present"] + and checks["authorization_text_matches"] + and checks["target_matches_packet"] + and checks["capture_complete_for_scoring"] + and checks["db_before_after_present"] + and checks["service_readback_present"] + and checks["final_visual_proof_present"] + and score_passes + ) + if not checks["capture_present"]: + status = "awaiting_capture" + else: + status = "pass" if receipt_ready else "fail" + return { + "generated_at_utc": datetime.now(timezone.utc).isoformat(), + "mode": "telegram_visible_direct_claim_capture_receipt", + "status": status, + "receipt_ready": receipt_ready, + "capture_present": checks["capture_present"], + "telegram_visible_messages_sent": bool(checks["capture_present"]), + "production_apply_executed": False, + "mutates_db": False, + "packet_path": str(packet_path), + "source_capture_path": str(source_capture_path) if source_capture_path else "", + "results_out": str(results_out), + "checks": checks, + "results": results, + "score": score, + "capture_template": blank_capture_template(packet) if capture is None else None, + "claim_ceiling": ( + "This receipt validates retained Telegram-visible capture evidence only. It does not send Telegram " + "messages, does not run production apply, and does not prove canonical DB mutation. A pass requires exact " + "DC-01..DC-06 messages, matching operator authorization, nonempty visible replies, DB/service readbacks, " + "visual proof, and a 6/6 direct-claim score." + ), + } + + +def write_json(path: Path, data: dict[str, Any]) -> None: + path.parent.mkdir(parents=True, exist_ok=True) + path.write_text(json.dumps(data, indent=2, sort_keys=True) + "\n", encoding="utf-8") + + +def write_markdown(path: Path, data: dict[str, Any]) -> None: + checks = data["checks"] + lines = [ + "# Telegram-Visible Direct-Claim Capture Receipt", + "", + f"Generated UTC: `{data['generated_at_utc']}`", + f"Mode: `{data['mode']}`", + f"Status: `{data['status']}`", + f"Receipt ready: `{data['receipt_ready']}`", + f"Capture present: `{data['capture_present']}`", + f"Telegram-visible messages sent: `{data['telegram_visible_messages_sent']}`", + f"Production apply executed: `{data['production_apply_executed']}`", + f"Mutates DB: `{data['mutates_db']}`", + "", + "## Checks", + "", + ] + for key, value in sorted(checks.items()): + lines.append(f"- `{key}`: `{value}`") + if data.get("score"): + score = data["score"] + lines.extend( + [ + "", + "## Score", + "", + f"- Pass: `{score['pass']}`", + f"- Prompts scored: `{score['passes']}/{score['expected_prompt_count']}`", + f"- Missing prompt IDs: `{', '.join(score['missing_prompt_ids'])}`", + f"- Unexpected prompt IDs: `{', '.join(score['unexpected_prompt_ids'])}`", + ] + ) + if data.get("capture_template"): + lines.extend( + [ + "", + "## Capture Template", + "", + "Populate `messages[].reply`, timestamp/id fields, `db_before_after`, `service_readback`, and " + "`capture_source.final_screenshot` / `capture_source.final_accessibility`, then rerun this script " + "with `--capture-json`.", + ] + ) + lines.extend(["", "## Claim Ceiling", "", data["claim_ceiling"], ""]) + path.parent.mkdir(parents=True, exist_ok=True) + path.write_text("\n".join(lines), encoding="utf-8") + + +def parse_args(argv: list[str] | None = None) -> argparse.Namespace: + parser = argparse.ArgumentParser(description=__doc__) + parser.add_argument("--packet", type=Path, default=DEFAULT_PACKET) + parser.add_argument("--capture-json", type=Path) + parser.add_argument("--out", type=Path, default=DEFAULT_OUT) + parser.add_argument("--markdown-out", type=Path, default=DEFAULT_MARKDOWN_OUT) + parser.add_argument("--results-out", type=Path, default=DEFAULT_RESULTS_OUT) + return parser.parse_args(argv) + + +def main(argv: list[str] | None = None) -> int: + args = parse_args(argv) + packet = _load_json(args.packet) + capture = _load_json(args.capture_json) if args.capture_json else None + receipt = build_receipt( + packet, + capture, + source_capture_path=args.capture_json, + packet_path=args.packet, + results_out=args.results_out, + ) + if receipt["results"]: + write_json(args.results_out, {"results": receipt["results"]}) + receipt["results_out"] = str(args.results_out) + write_json(args.out, receipt) + write_markdown(args.markdown_out, receipt) + print( + json.dumps( + { + "out": str(args.out), + "markdown_out": str(args.markdown_out), + "results_out": str(args.results_out) if receipt["results"] else "", + "status": receipt["status"], + "receipt_ready": receipt["receipt_ready"], + }, + indent=2, + sort_keys=True, + ) + ) + return 0 if receipt["status"] in {"pass", "awaiting_capture"} else 2 + + +if __name__ == "__main__": + raise SystemExit(main()) diff --git a/scripts/build_telegram_visible_direct_claim_authorization_packet.py b/scripts/build_telegram_visible_direct_claim_authorization_packet.py index 5dbe572..bdc81df 100644 --- a/scripts/build_telegram_visible_direct_claim_authorization_packet.py +++ b/scripts/build_telegram_visible_direct_claim_authorization_packet.py @@ -25,6 +25,9 @@ DEFAULT_LIVE_OPEN_SCORE = REPORT_DIR / "telegram-live-open-ended-suite-score-cur DEFAULT_HANDLER_SUITE = REPORT_DIR / "telegram-handler-direct-claim-suite-current.json" DEFAULT_HANDLER_SCORE = REPORT_DIR / "telegram-handler-direct-claim-suite-score-current.json" DEFAULT_GCP_PROBE = REPORT_DIR / "gcp-db-parity-current-probe-current.json" +DEFAULT_CAPTURE_RECEIPT = REPORT_DIR / "telegram-visible-direct-claim-capture-receipt-current.json" +DEFAULT_CAPTURE_RECEIPT_MARKDOWN = REPORT_DIR / "telegram-visible-direct-claim-capture-receipt-current.md" +DEFAULT_CAPTURE_RESULTS = REPORT_DIR / "telegram-visible-direct-claim-capture-results-current.json" DEFAULT_CHAT_ID = "-5146042086" DEFAULT_CHAT_LABEL = "Leo" DEFAULT_PROOF_DIR = "outputs/telegram-visible-direct-claim-suite-20260710" @@ -127,6 +130,9 @@ def build_packet( "final_accessibility": f"{proof_dir}/telegram-visible-direct-claim-suite-final-accessibility.txt", "db_before_after": f"{proof_dir}/telegram-visible-direct-claim-suite-db-before-after.json", "service_readback": f"{proof_dir}/telegram-visible-direct-claim-suite-service-readback.txt", + "capture_receipt_json": str(DEFAULT_CAPTURE_RECEIPT), + "capture_receipt_markdown": str(DEFAULT_CAPTURE_RECEIPT_MARKDOWN), + "capture_results_json": str(DEFAULT_CAPTURE_RESULTS), } checks = { @@ -184,7 +190,7 @@ def build_packet( "Send exactly the six raw DC-01..DC-06 messages to Telegram group Leo.", "Capture each Telegram-visible Leo reply plus a final screenshot/accessibility readback.", "Read DB counts and service state after sending.", - "Score the retained replies and update the current truth index.", + "Assemble the retained capture receipt and score it before updating the current truth index.", ], "do_not_run_without": [ "Exact operator authorization text naming the Telegram group and six-message scope.", diff --git a/tests/test_assemble_telegram_visible_direct_claim_capture_receipt.py b/tests/test_assemble_telegram_visible_direct_claim_capture_receipt.py new file mode 100644 index 0000000..d994878 --- /dev/null +++ b/tests/test_assemble_telegram_visible_direct_claim_capture_receipt.py @@ -0,0 +1,142 @@ +"""Tests for scripts/assemble_telegram_visible_direct_claim_capture_receipt.py.""" + +from __future__ import annotations + +import argparse +import json +import sys +from pathlib import Path + +REPO_ROOT = Path(__file__).resolve().parents[1] +sys.path.insert(0, str(REPO_ROOT / "scripts")) + +import assemble_telegram_visible_direct_claim_capture_receipt as receipt # noqa: E402 + + +def load_packet() -> dict: + return json.loads(receipt.DEFAULT_PACKET.read_text(encoding="utf-8")) + + +def handler_replies() -> dict[str, str]: + data = json.loads((REPO_ROOT / "docs/reports/leo-working-state-20260709/telegram-handler-direct-claim-suite-current.json").read_text(encoding="utf-8")) + return {item["prompt_id"]: item["reply"] for item in data["results"]} + + +def good_capture(packet: dict) -> dict: + replies = handler_replies() + messages = [] + for index, item in enumerate(packet["exact_messages"], start=1): + messages.append( + { + "prompt_id": item["prompt_id"], + "sent_text": item["message"], + "reply": replies[item["prompt_id"]], + "sent_at_utc": f"2026-07-10T03:0{index}:00Z", + "reply_at_utc": f"2026-07-10T03:0{index}:30Z", + "telegram_message_id": f"sent-{index}", + "reply_message_id": f"reply-{index}", + } + ) + return { + "operator_authorization_text": packet["explicit_operator_authorization_text"], + "capture_source": { + "platform": "telegram", + "chat_label": "Leo", + "chat_id": "-5146042086", + "captured_at_utc": "2026-07-10T03:08:00Z", + "captured_by": "codex", + "final_screenshot": "outputs/telegram-visible-direct-claim-suite-20260710/final.png", + "final_accessibility": "outputs/telegram-visible-direct-claim-suite-20260710/final.txt", + }, + "db_before_after": { + "before": {"public.claims": 1837}, + "after": {"public.claims": 1837}, + "db_counts_changed": False, + }, + "service_readback": { + "before": {"ActiveState": "active", "SubState": "running"}, + "after": {"ActiveState": "active", "SubState": "running"}, + }, + "messages": messages, + } + + +def test_receipt_without_capture_emits_awaiting_capture_template(): + packet = load_packet() + + data = receipt.build_receipt(packet, None, source_capture_path=None) + + assert data["status"] == "awaiting_capture" + assert data["receipt_ready"] is False + assert data["capture_template"]["messages"][0]["prompt_id"] == "DC-01" + assert data["checks"]["missing_prompt_ids"] == ["DC-01", "DC-02", "DC-03", "DC-04", "DC-05", "DC-06"] + + +def test_good_capture_scores_and_receipt_passes(): + packet = load_packet() + + data = receipt.build_receipt(packet, good_capture(packet), source_capture_path=Path("capture.json")) + + assert data["status"] == "pass" + assert data["receipt_ready"] is True + assert data["score"]["pass"] is True + assert data["score"]["passes"] == data["score"]["expected_prompt_count"] == 6 + assert len(data["results"]) == 6 + assert data["results"][0]["evidence_tier"] == "telegram_visible_capture" + + +def test_capture_with_message_text_mismatch_fails(): + packet = load_packet() + capture = good_capture(packet) + capture["messages"][0]["sent_text"] = "wrong" + + data = receipt.build_receipt(packet, capture, source_capture_path=Path("capture.json")) + + assert data["status"] == "fail" + assert data["receipt_ready"] is False + assert data["checks"]["sent_text_exact"] is False + assert data["checks"]["text_mismatch_prompt_ids"] == ["DC-01"] + + +def test_capture_with_empty_reply_fails(): + packet = load_packet() + capture = good_capture(packet) + capture["messages"][1]["reply"] = "" + + data = receipt.build_receipt(packet, capture, source_capture_path=Path("capture.json")) + + assert data["status"] == "fail" + assert data["receipt_ready"] is False + assert data["checks"]["replies_nonempty"] is False + assert data["checks"]["empty_reply_prompt_ids"] == ["DC-02"] + + +def test_main_writes_awaiting_capture_artifacts(tmp_path: Path): + out = tmp_path / "receipt.json" + md = tmp_path / "receipt.md" + results = tmp_path / "results.json" + + code = receipt.main(["--out", str(out), "--markdown-out", str(md), "--results-out", str(results)]) + + assert code == 0 + assert json.loads(out.read_text(encoding="utf-8"))["status"] == "awaiting_capture" + assert "Telegram-Visible Direct-Claim Capture Receipt" in md.read_text(encoding="utf-8") + assert not results.exists() + + +def test_receipt_records_cli_override_paths(tmp_path: Path): + packet_path = tmp_path / "packet.json" + results = tmp_path / "results.json" + packet = load_packet() + + packet_path.write_text(json.dumps(packet), encoding="utf-8") + data = receipt.build_receipt( + packet, + good_capture(packet), + source_capture_path=tmp_path / "capture.json", + packet_path=packet_path, + results_out=results, + ) + + assert data["packet_path"] == str(packet_path) + assert data["results_out"] == str(results) diff --git a/tests/test_build_telegram_visible_direct_claim_authorization_packet.py b/tests/test_build_telegram_visible_direct_claim_authorization_packet.py index 2da9e5a..866ff55 100644 --- a/tests/test_build_telegram_visible_direct_claim_authorization_packet.py +++ b/tests/test_build_telegram_visible_direct_claim_authorization_packet.py @@ -31,6 +31,12 @@ def test_packet_ready_but_never_sends_messages(): "explicit_operator_authorization_text" ] assert "Do not run production DB apply" in report["explicit_operator_authorization_text"] + assert report["expected_proof_paths_after_authorized_run"]["capture_receipt_json"] == str( + packet.DEFAULT_CAPTURE_RECEIPT + ) + assert report["expected_proof_paths_after_authorized_run"]["capture_results_json"] == str( + packet.DEFAULT_CAPTURE_RESULTS + ) assert "does not send Telegram messages" in report["claim_ceiling"]