Repository navigation
Add a json format for tools to read - #74
Merged
Merged
Conversation
The reports were written for people; a tool that wanted the suggested version or the breaking changes had to scrape the console. --format json writes api-changes.json with the suggested version change, the number of breaking changes, and every assembly's changes as a tree, each with the version change it calls for. Co-Authored-By: Claude Opus 5.5 <[email protected]>
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.
--format jsonwritesapi-changes.json: the suggested version change, the number of breaking changes, and each assembly's changes as a tree.Prompt summary: The tool is being dusted off. The next steps post a comment and set release labels on pull requests, and a GitHub Action passes the suggested version on as an output. Each of those needs the result in a form a program can read, not console text to scrape.
Why
Every format was written for people. To find the suggested version, a script had to match
[diff] Suggested version change: Minoron the console. Nothing machine-readable said which changes break.What
One document for all assemblies
The top level holds
suggestedVersionChange,breakingChanges,assemblies,removedAssembliesandaddedAssemblies. Each assembly has its ownsuggestedVersionChange,breakingChangesandchanges. A change has akind(Type,Method,Property,Field,Event,Attribute,AssemblyReferenceorDeclaration), anameas the other reports show it, achange(added,removedormodified) and thesuggestedVersionChangeit calls for on its own. A new abstract orrequiredmember also hasaddsObligation: true. Nested changes sit underchanges.The same rules as the comment
breakingChangescounts the changes that on their own call forMajor, the count the GitHub comment shows. The writer usesUtf8JsonWriterwithout reflection, so it works in the native-AOT build:./build.sh smokeaotpasses.Verify
DiffCommandTestsnow snapshots every scenario injsontoo.🤖 Generated with Claude Code