Skip to content

The reserve must write the DOI into the article, not only its metadata - #49

Merged
lmoresi merged 2 commits into
mainfrom
bugfix/reserve-syncs-front-matter
Sep 2, 2026
Merged

lmoresi merged 2 commits into
mainfrom
bugfix/reserve-syncs-front-matter

Conversation

@lmoresi

@lmoresi lmoresi commented Sep 2, 2026

Copy link
Copy Markdown
Contributor

The first live reserve opened #47, and its tests failed — correctly.
test_the_pdf_carries_the_archival_doi_once_a_note_is_deposited compares the
article's front matter doi: against archive_doi in metadata.yml, and the
reserve had written only the second.

That is not a test being fussy. The article's front matter is where the PDF's
title page takes the DOI from, so publishing from that state would have produced
an archival PDF with no DOI on it — the one thing the reserve-before-build
order exists to prevent.

sync_archival.py already copies both the DOI and archived_at across; it was
simply never called, being a script somebody ran by hand. The reserve now runs
it, so a request carries both files and the publish still needs nothing written
back afterwards.

Found by running the flow against the live API rather than by reading it — which
is the argument for having done #47 by hand before turning on the schedule.

Underworld development team with AI support from Claude Code

The first live reserve opened a request whose tests failed, correctly:
`test_the_pdf_carries_the_archival_doi_once_a_note_is_deposited` compares
the article's front matter `doi:` against `archive_doi` in metadata.yml,
and the reserve had written only the second.

That is not a test being fussy. The article's front matter is where the
PDF's title page takes the DOI from, so publishing from that state would
have produced an archival PDF with no DOI on it -- the one thing the
reserve-before-build order exists to prevent.

sync_archival.py already copies both the DOI and archived_at across; it
was simply never called, being a script somebody ran by hand. The reserve
now runs it, so the request carries both files and the publish still needs
nothing written back afterwards.

Found by running the flow against the live API rather than by reading it.

Underworld development team with AI support from Claude Code
…front-matter

# Conflicts:
#	tests/test_migration.py
@lmoresi
lmoresi merged commit 0904ad9 into main Sep 2, 2026
2 checks passed
lmoresi added a commit that referenced this pull request Sep 2, 2026
The reserve that opened this request wrote only metadata.yml, so the
article's own front matter carried no DOI -- and that is where the PDF's
title page takes it from. Publishing from that state would have deposited
a PDF with no DOI on it.

Fixed at source in the reserve itself (#49); this brings the request that
found it up to the same state, rather than throwing away a DOI that is
already reserved.

Underworld development team with AI support from Claude Code
lmoresi added a commit that referenced this pull request Sep 2, 2026
* Deposit: boundary-conditions-on-non-planar-boundaries

A draft and a DOI are reserved for this note; neither is public. The
identifiers are in its metadata.yml, so merging this approves the
deposit and records it in one step.

Opened automatically because the note is on main without a record.

* Write the reserved DOI into the article front matter too

The reserve that opened this request wrote only metadata.yml, so the
article's own front matter carried no DOI -- and that is where the PDF's
title page takes it from. Publishing from that state would have deposited
a PDF with no DOI on it.

Fixed at source in the reserve itself (#49); this brings the request that
found it up to the same state, rather than throwing away a DOI that is
already reserved.

Underworld development team with AI support from Claude Code

---------

Co-authored-by: underworld-technical-notes <help@underworldcode.org>
Co-authored-by: lmoresi <louis.moresi@anu.edu.au>
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