Add support for checking package exports for changed API #1558
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.
Currently API tools only check for API changes on the bundle level, but even more important are checks on the exported packages. If the package version is not properly incremented this can lead to method not found or similar errors, also consumers of the package can not depend on the package version reliable to get new API.
This now adds some basic checks to check for API changes on the package level, compare it with the baseline and suggest a new version based on the resulting delta being a breaking or non breaking change.
This is a very basic first step. We need (see TODOs) and likely want to further improve this when we use it, for example currently all deltas are assumed to be important, we might discover places where it is actually not required to make a minor change but only a micro change (currently not used at all).