Repository navigation
fix(notifications): single daily-digest PAPER preview with opt-in send - #510
Merged
Merged
Conversation
Replace the six-message PAPER notification preview pack with one consolidated message rendered by the pinned QRS daily-digest snapshot. Vendor the missing display_names.json into the snapshot with a provenance entry. The workflow_dispatch input `send` defaults to false and only prints the preview to the job log; GCP auth steps now run only when sending.
|
Important
This repository does not receive automatic reviews because it has fewer than 10 stars.
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
AI assistance
Originally authored with Codex (OpenAI); the original model was not recorded. PR governance metadata updated with Codex (GPT-6).
What changed
The PAPER Notification Preview workflow previously sent one Telegram message per status (~6 per run). This PR makes the preview render one consolidated message in the unified QuantSentinel daily-digest format, reusing the pinned QRS digest renderer snapshot in
tests/fixtures/qrs_notification_716(no new format invented).scripts/send_paper_notification_preview.pynow builds a singleDailyDigestInputwith one synthetic run entry (firstrade/tqqq_growth_income, statusok, zero orders/fills) and renders it via the snapshot'srender_daily_digest. The preview-profile-enabled guard is preserved.display_names.json(the renderer reads it at runtime). This PR vendors the authentic file from QRS commit160933e(byte-identical to the copy pinned in other platform repos) and records it inprovenance.json.workflow_dispatch-only and gains a boolean inputsend(defaultfalse). Whenfalse, the run only prints the rendered preview to the job log and sends nothing; GCP auth steps are skipped in that case. Whentrue, the single message is delivered through the existing Telegram sender.RUNTIME_TARGET_ENABLEDfail-closed guard is preserved.How verified
uv run --no-sync python -m pytest -q tests/test_paper_notification_preview.py→ 12 passed.uv run --no-sync ruff check scripts/send_paper_notification_preview.py tests/test_paper_notification_preview.py→ all checks passed.NO_GCE_CHECK=true: main 1712 passed; this PR head 1715 passed; no failures on either revision. The originally reported 13 failures were not reproduced.Tests now assert: single-message digest format in zh/en, exactly-one send call, no broker/execution imports, fail-closed without a Telegram target, print-only behavior when send is false, and workflow static constraints (no push/PR/schedule triggers,
sendinput default false, GCP auth gated oninputs.send, pinnedsetup-uv).Why
Consolidate the PAPER preview into one daily digest and require an explicit opt-in to send it.
Risk
High: this PR changes
.github/workflows/paper-notification-preview.yml. The preview remains manual, withsenddefaulting tofalse. Trading and order-execution behavior is unchanged. Owner approval remains for the path-based risk gate. This governance update changes PR metadata only; it does not deploy or send notifications.Supersedes #506