Skip to content

Process edited sources using immutable revisions - #24

Merged
AyobamiH merged 2 commits into
mainfrom
fix/source-content-revisions-20261103
Nov 3, 2026
Merged

AyobamiH merged 2 commits into
mainfrom
fix/source-content-revisions-20261103

Conversation

@AyobamiH

@AyobamiH AyobamiH commented Nov 3, 2026 •

Copy link
Copy Markdown
Collaborator

Editing a source that already had extracted angles returned the source to the bank, but the worker excluded its URL permanently. Old unused angles could also be presented as draftable after the source changed.

This change selects work through revision-aware database views, requires an immutable source revision on the claimed row before model work, and excludes superseded angles from new drafting and inventory. A completed extraction replay reports recovered existing angles rather than claiming they were newly created. Existing approved or published queue items keep their identities and content.

The worker requires the paired source-revisions-v1 database capability and fails closed if it is absent. Deploy only after application migration 20261103135010_source_content_revisions.sql and its staging/restart gate pass. Generation and general provider dispatch remain disabled during rollout. Merging this source does not authorize deployment or model calls.

Validation: full isolated npm run ci passed (typecheck, complete regression chain, build, compiled-runtime smoke). Five focused source-revision scenarios intercept all model/HTTP requests and cover edited content, exact replay, return to a completed earlier revision, wrong/missing claim scope, and a lost commit response followed by exact RPC replay. The paired application change supplies real Postgres RLS, claim, approval-preservation and zero-angle tests.

Acceptance ledger: https://github.com/AyobamiH/oneclickpostfactory/issues/46

Additional release gate: 87 native readiness/operator tests and 11 real Workerd transport tests pass, including rejection of a database without source-revisions-v1. The initial Workerd success fixture was updated for the new required capability; the runtime guard remains strict.

@AyobamiH
AyobamiH merged commit 0eb55c2 into main Nov 3, 2026
3 checks passed
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