# Evidence Topic: Monthly publication live acceptance ## Metadata - Date: 2026-07-30 - Status: Active - Scope: migration 012, dedicated worker, controlled `booking_test`, local monthly artifacts and ARR2 loopback Web - Confidence: Fact - Source: migration rollback probes, automated tests, read-only PostgreSQL queries, workbook reopen inspection and live Web API/download checks - Last verified: 2026-07-30 - Stale trigger: migration/report schema, formula layout, output storage, worker acknowledgement or Web download behavior changes ## Question Does a successful daily commit now produce a durable, visible and downloadable monthly report with the correct ARRIVAL watermark and `TOTAL PRICE` formulas? ## Evidence ### Migration and publication state - `database/012_monthly_report_publication.sql` was executed inside an uncommitted up/down probe, then in a synthetic active-publication probe, and both left no objects/data after rollback. - A privacy-minimized pre-migration checkpoint was created at `runtime/backups/booking_test_pre_012_20260730T151922+0800/manifest.json`; its SHA-256 is `230206eb074fd5877132744eb592b3dc6cd6638d12a3dd4d71a8101a9bd2998e`. - Migration 012 was then applied to `booking_test`. It adds three metadata-only `reporting` tables and permits controlled `local` monthly artifacts; 008–011 were not edited or replayed. - Current read-only state is 2 Finance daily versions, 120 active facts, one active monthly run, one local `monthly_xlsx`, one local `result_json`, and two published daily-commit events. ### ARRIVAL derivation and idempotency - Event 3 referenced daily version 2 with retained `ARRIVAL=2026-07-27`; event 9 referenced daily version 4 with retained `ARRIVAL=2026-07-21`. - The worker looked up those facts by `daily_version_id`, ignored payload dates/filenames, and selected the July scope. - Both events resolved to report ID 1/version 1 with `as_of_date=2026-07-27`, exactly the maximum `ARRIVAL` in the current 120-row monthly snapshot. The second event reused the published snapshot instead of creating a duplicate. - Both events became `published` after one attempt and only after the report and its two artifacts were registered. ### Workbook and Web - The active report contains 120 rows across five worksheets: LIANTAI-GROUP 26, LIANTAI-FIT 25, QBD 55, DY-AI-Easy-KB 0 and FENGRUN 14. - Reopening the real workbook found exactly 120 formulas, all in the `TOTAL PRICE` data cells and all equal to the expected row-relative `=R[row]*C[row]*G[row]`; there were zero missing, mismatched or unauthorized formulas. - The workbook is 20,741 bytes with SHA-256 `a43cdac3f6d97f6b73f635d0f386cffd0ad8b6416e8f92a7b6afc2f79f1e8635`. - `/api/monthly-runs?month=2026-07` returns the active database report. `/api/download/monthly?report_id=1` returned bytes matching the registered size and hash. - The primary page no longer contains month, cutoff or manual-generate controls and explains the max-ARRIVAL policy. - The final full discovery passed 291 tests in 108.2 seconds with 7 explained environment/fixture skips and no failures or errors; this included real monthly XLSX generation/reopen coverage using the configured builder runtime. ### Later live versions and automatic page discovery - Two later user uploads advanced the live publication history to V03 active and V02/V01 superseded. All four daily-commit events are published. - V03 contains 308 rows across six channels. Its persisted `as_of_date` and max current fact `ARRIVAL` are both 2026-07-27. - An independent reopen of V03 found exactly 308 expected `TOTAL PRICE` formulas and zero bad formulas. The file is 40,635 bytes with SHA-256 `494fb78283f68cb7bffce2501b3531613c494d148a56a7ccc8d2aabe46b1e29c`, matching its registered artifact. - The monthly page was changed to remove its refresh button and poll only while visible/active. Browser inspection rendered V03/V02/V01 with download links and `自动更新 · 4 秒`; Web access logs showed repeated `/api/monthly-runs` reads at the intended cadence without a click or reload. - A subsequent 07-23 upload committed daily version 7 with 109 retained rows and advanced publication to V04 active with 417 rows. All five daily-commit events are published; V03/V02/V01 remain superseded history. ### Data-quality caveat discovered after publication - A later read-only Channel BI reconciliation proved that Finance version 2 in every July snapshot is the database acceptance run `mvp-v1-fixture-20260727`, sourced from `synthetic.xml` with provider `local_fixture`. - Publication, lineage, formula and download mechanics remain verified, but V01/V02/V03/V04 are not clean business-data acceptance artifacts: the fixture adds one row and makes 2026-07-27 the maximum included ARRIVAL. - See [Channel BI post-update data contamination](2026-07-30-channel-bi-post-update-data-contamination.md) for the measured impact and repair boundary. ## Finding The original publication-identity discrepancy is resolved in the controlled local runtime: monthly success now means a persisted report identity with registered, hash-checked downloadable bytes. The “更新至” label is based on the latest included `ARRIVAL`, formulas are present and verified, automatic dispatch is performed by a separate durable worker, and the open monthly page discovers the published version without manual refresh. Current July business values remain subject to the fixture-contamination caveat above until controlled repair and republication. ## Remaining Boundary The workstation already runs Web and worker separately. Production Compose packaging must still provide the required Node/artifact-tool runtime and shared output volume before enabling an equivalent managed worker service.