Repository navigation
feat(api): completion events link to results; recovery by polling (#1232) - #1243
Merged
Merged
Conversation
…1232) finish returns the snapshot holding the run's results and publishes it in FinishReport, the same unchecked output path the entity counts cross by, because the control plane cannot open a lake. job.succeeded for a run carries run_id, snapshot and links that read exactly it; an export carries export_id and its status/download links. run_snapshot_read.rs proves the announced snapshot is what GET …/runs serves, so a missed delivery is recovered by polling without a re-run. Co-Authored-By: Claude Opus 5.5 <[email protected]>
athvin
marked this pull request as ready for review
November 25, 2026 20:11
7 tasks done
athvin
temporarily deployed
to
marketing-preview
November 25, 2026 20:13 — with
GitHub Actions
Inactive
This branch was previously deployed
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.
Closes #1232
What
job.*webhook payloads now say where the results are:run_all_*,correct,apply_corrections) carriesrun_id. On success it also carries thesnapshotholding its results andlinks.golden_records/links.duplicatesthat read exactly that snapshot, pluslinks.runs.export_id, itssnapshot,links.status, andlinks.downloadonce it succeeded.How the snapshot gets there: the control plane cannot open a lake. So
finish(viaer_cli::write_run_end, which now returns the snapshot it stamps) publishes it inFinishReport. That is the same output path the entity counts already cross by (O3c-2), and the executor reads it at settle.Recovery without a re-run:
GET …/runsserves each run'ssnapshot(#1229), so a subscriber that missed the delivery polls the same number. Thejob.succeededcatalog description says so.Why
#1232, part of #521.
Proof
make check: 1,194 passed, 0 failed.er-server+er-cli --testsagainst Postgres withDEDUPE_E2E_DUCKLAKE=1: 502 passed.make frontend: 963 passed, 1 failed (grow.spec.ts:339, mobile-safari). This PR changes no frontend file. The single failing mobile-safari spec has been a different spec on each of the last three local runs, which is the shard-flake pattern; the required Playwright tier is the judge.job_event_data_tests(4):run_id, no snapshot and no links;run_snapshot_read.rs: the announced snapshot equals the oneGET …/runsserves. That is the event route and the poll route agreeing.plans.rs: the settle path's uncheckedoutput["doc"]["snapshot"]key round-trips, next to the existingentity_countsone.an_export_links_its_download_only_once_it_succeededRisk & rollback
Additive payload fields: a subscriber that ignores unknown keys is unaffected.
FinishReport.snapshotis#[serde(default)], so older task rows still read. The otheremit_job_eventcall sites (cancel, the legacy helper) passNone. Rollback:git revert <merge-sha>.Post-merge ledger
Closed by: agent · session
Claude Code:d1e3b2dc-3174-4091-9c30-c08fc4820306onMac· 2026-11-25T20:25:36Zmainis green with this change on it: merge376da162. Push runs: infra 45692865453 success, devcontainer 45692865619 success, frontend 45692865565 success, images 45692865751 success, rust 45692865741 success.images: built and succeeded for376da162.deployconverged. Process proof was read once the AWS session was restored (2026-11-26). The live colour in dev (ci/web-api-green-5d5f9c8844-88dxb, logged"er-server listening"at 01:36:40Z) and prod (app/web-api-blue-7544598cbb-8rjth, at 01:51:39Z) both runer-api@sha256:5d993716…, built frombae09b2e, which contains this merge (git merge-base --is-ancestor 376da162 bae09b2eholds). (Earlier note: run 45693614034 (DEPLOY_SHA: 376da162) succeeded, but the AWS SSO session has been expired since 12:10Z, so the live pods'er-server listeningline could not be read. To be ticked afteraws sso login.)deployis green.driftandkindwere already red on schedule before feat(api): typed response structs, batch 3 — reviews+merges (#1193) #1202.job.succeededcatalog description, which subscribers read, names the payload fields and the polling recovery path.Specific to this change
Context — plan, discoveries, measurements, files
Plan
Discoveries
Measurements
Files