Skip to content

Use the newer committed or artifact data in staging - #886

Merged
LukasWallrich merged 1 commit into
mainfrom
fix/staging-data-freshness
Sep 10, 2026
Merged

Use the newer committed or artifact data in staging#886
LukasWallrich merged 1 commit into
mainfrom
fix/staging-data-freshness

Conversation

@LukasWallrich

Copy link
Copy Markdown
Contributor

Staging can lose newer committed data when an older data artifact is extracted over the aggregated PR checkout. For example, a build triggered by another PR replaced #880’s discipline leads and refreshed resources with stale JSON, even though #880 was included in the aggregate. Workflow edits in #880 only governed runs triggered with that workflow version.

Compare freshness for every artifact file before overlaying it. Data Processing now records content hashes and per-file timestamps: unchanged Git files retain their last non-merge commit time; regenerated files use their generation mtime. Staging selects the newer content, keeps committed content on ties, preserves newer committed deletions, and logs every differing-file decision. Artifact download/upload times and synthetic staging merge times do not determine data freshness.

Legacy artifacts without the manifest retain committed versions on conflicts and emit a warning; artifact-only files are still added. Hash mismatches fail before any files are copied. The same selection applies after an artifact-download retry.

Validation: 12 regression tests passed, including both freshness directions, ties, synthetic merges, legacy artifacts, deletions, integrity checks, and local-edit protection. Generated a manifest successfully for all 2,820 artifact-scope files in the real repository; both workflows parse without duplicate YAML keys.

This workflow fix needs to land on main independently of #880 so staging runs triggered by other PRs and manual/scheduled runs inherit it. No production deployment selection behavior is changed.

@github-actions

Copy link
Copy Markdown
Contributor

👍 All image files/references (if any) are in webp format, in line with our policy.

@github-actions

Copy link
Copy Markdown
Contributor

✅ Spell Check Passed

No spelling issues found when checking 4 changed file(s)! 🎉

@LukasWallrich
LukasWallrich marked this pull request as ready for review September 10, 2026 19:01
@LukasWallrich
LukasWallrich requested a review from a team as a code owner September 10, 2026 19:01
@LukasWallrich
LukasWallrich merged commit c8e0231 into main Sep 10, 2026
6 checks passed
@LukasWallrich
LukasWallrich deleted the fix/staging-data-freshness branch September 10, 2026 19:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant