Skip to content

Audit versioning workflow for DOI integration - #116

Merged
neuromechanist merged 1 commit into
devfrom
113-audit-versioning-and-tagging-workflow-for-doi-integration
Feb 11, 2026
Merged

neuromechanist merged 1 commit into
devfrom
113-audit-versioning-and-tagging-workflow-for-doi-integration

Conversation

@neuromechanist

Copy link
Copy Markdown
Contributor

Summary

  • Fixes version DOI creation idempotency: createEzidVersionDoi now handles "already exists" errors from EZID, matching the pattern already used by createEzidConceptDoi. This makes webhook retries safe.
  • Adds semver validation to the publish-version-doi webhook: strips leading v prefix, rejects pre-release versions (1.0.0-beta), non-semver strings, and build metadata with a skipped: true response (200 status).
  • Adds tests for version format validation and v-prefix stripping.

Audit findings (no changes needed)

  • DB idempotency: INSERT OR IGNORE + UNIQUE(dataset_id, version) works correctly
  • Tag exists check: workflow checks git rev-parse before creating tag
  • HasVersion relations: queries all existing versions before concept DOI update
  • Manifest generation: S3 overwrite is idempotent
  • Concept DOI update failure: non-fatal with warnings surfaced in response

Test plan

  • bun test passes (354 pass, 0 fail)
  • bunx biome check passes on changed source files
  • Verify webhook retry returns existing DOI without error
  • Verify v1.0.0 is normalized to 1.0.0 before DOI minting
  • Verify 1.0.0-beta is rejected with skipped status

Closes #113

- Add "already exists" try-catch to createEzidVersionDoi matching
  the pattern from createEzidConceptDoi for webhook retry safety
- Add semver validation to webhook: strip v-prefix, reject
  pre-release and non-semver versions with skipped status
- Log skipped versions for troubleshooting
- Add tests for version format validation and v-prefix stripping

Closes #113
@neuromechanist
neuromechanist force-pushed the 113-audit-versioning-and-tagging-workflow-for-doi-integration branch from c925559 to 8263037 Compare February 11, 2026 21:43
@neuromechanist
neuromechanist merged commit c8f4b06 into dev Feb 11, 2026
1 check passed
@neuromechanist
neuromechanist deleted the 113-audit-versioning-and-tagging-workflow-for-doi-integration branch February 11, 2026 21:43
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