Let integration tests resolve OpenRewrite snapshots from the Code Genome Project - #1202
Merged
Conversation
…ome Project The itf integration tests run nested Maven builds with their own local repository, so they resolve the plugin under test and its transitives from scratch. Since OpenRewrite snapshots are published solely to the Code Genome Project, the post-release `rewrite.version` bump to 8.92.0-SNAPSHOT broke them. The fixture poms declared a repository with id `codegenome` but snapshots disabled; Maven dedupes remote repositories by id, so that definition shadowed the snapshot-enabled one the plugin's own pom contributes, leaving only ossrh-snapshots eligible for snapshots. `BasicIT.resolves_settings` additionally replaces the user settings, dropping the credentials the Code Genome Project requires.
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.
CI has been deterministically red since the post-release
Bump rewrite.version propertycommit movedrewrite.versionto8.92.0-SNAPSHOT: OpenRewrite snapshots are published solely to the Code Genome Project, and the itf integration tests run nested Maven builds with their own local repository, so they resolve the plugin's transitives from scratch.The 11 fixture poms declared a repository with id
codegenomebut snapshots disabled, and since Maven dedupes remote repositories by id that definition shadowed the snapshot-enabled one the plugin's own pom contributes — leaving onlyossrh-snapshotseligible for snapshots, which 404s (KotlinITwas the only fixture pulling in modules the plugin doesn't already depend on, viarewrite-all). This enables snapshots on those repositories and adds thecodegenomeserver credentials toBasicIT.resolves_settings' ownsettings-user.xml, which replaces the user settings written by CI and so was reaching the Code Genome Project anonymously (401 on metadata, then 422 on the non-timestamped pom).The "checksum warnings the ITs assert against" rationale in the old comment no longer reproduces: the last CI run fetched snapshot metadata from the Code Genome Project without a single integrity warning, and the served
maven-metadata.xml.sha1now matches the served bytes. Fork builds get no credentials and are unaffected by this change (they are already broken for the release line too, sincerewrite-core:8.91.0is not on Maven Central).