Validate entries against omit_pr and omit_author - #32
Merged
Conversation
Entries written directly to disk could carry 'prs' or 'authors' metadata even when the project config sets 'omit_pr: true' or 'omit_author: true', because those options only guard the 'add' command. The 'validate' command now reports an error for such entries. Co-Authored-By: Claude Fable 5 <[email protected]>
Co-Authored-By: Claude Fable 5 <[email protected]>
This was referenced Jul 1, 2026
mavam
approved these changes
Jul 2, 2026
…d-metadata # Conflicts: # tests/test_cli.py
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.
🔍 Problem
omit_pr: true/omit_author: trueonly guard theaddcommand.prs/authorsmetadata slips into projects that forbid it.omit_pr: true, yet published entries carry PR numbers that render as 404 links to the public repo.🛠️ Solution
validatenow errors on entries carryingprsmetadata when the config setsomit_pr: true, andauthorsmetadata when it setsomit_author: true.💬 Review
- Projects that enabled the options after entries were already published will start failing validation until the offending fields are scrubbed — intentional, since those fields violate the config's stated policy.
- Composes with the new
📚 Docs PR: tenzir/content#80require_proption from Require PR metadata for changelog entries #34, which already skips its check whenomit_pris set.📎 Related: #33