Add verifiable publication metadata exports and explicit API contracts - #30
Merged
Merged
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
This branch was successfully 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.
Publication searches previously had no export inventory tying returned metadata to stored revisions. This change adds GET /api/v1/publications/export/manifest with bounded title search, stable identifier ordering, origin labels, revisions, stored content hashes, and retrieval timestamps. A SHA-256 fingerprint covers both the manifest and exported items. Counts and rows share one PostgreSQL repeatable-read snapshot per request; separate pages are explicitly not a frozen corpus snapshot.
Also carries forward two tested changes that remained on the previous working branch after PR #29: explicit create_app(database_url=None) configuration for database-independent operation, and the citation-export schema discovery endpoint. Synthetic publication metadata remains labeled and export inclusion does not grant citation eligibility.
Validation: Ruff passed; local pytest reports 64 passed and 6 skipped (PostgreSQL integration requires CI), with two existing dependency deprecation warnings. Structural documentation audit passes for all 80 tracked Markdown documents. New tests independently recompute the fingerprint and cover freshness/content changes, pagination bounds, missing storage, and PostgreSQL revision/pagination behavior. API documentation includes the exact verification algorithm and export limitations.
GitHub Actions validation: all 70 Python tests passed with PostgreSQL configured, including the new persisted export integration test; Ruff passed. Both push and pull-request Python jobs succeeded.