-
Notifications
You must be signed in to change notification settings - Fork 80
Group annotations by dependency and print a warning if the dependency is missing #752
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Group annotations by dependency and print a warning if the dependency is missing #752
Conversation
55c8c3e to
97cced1
Compare
| AnnotationUtils.registerClassesFromAnnotationForReflection(testClass, registry, FieldSource.class, JupiterConfigProvider::handleFieldSource); | ||
| } catch (NoClassDefFoundError e) { | ||
| System.out.println("[junit-platform-native] Cannot register @FieldSource annotation from org.junit.jupiter.params." + | ||
| " Please verify that you have this dependency (with version greater than JUnit 5.13) if you want to use this annotation."); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
mmm, I'm not sure we want to print that out. It will be annoying for users who do NOT want this.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
So we should use debug()? Could we see the failure at runtime because we didn't register those annotations for reflection (and users won't see why we didn't register them)?
05c0723 to
db6c391
Compare
…1.0 to 0.11.1 [skip ci] Bumps [org.graalvm.buildtools:native-maven-plugin](https://github.com/graalvm/native-build-tools) from 0.11.0 to 0.11.1. Release notes *Sourced from [org.graalvm.buildtools:native-maven-plugin's releases](https://github.com/graalvm/native-build-tools/releases).* > 0.11.1 > ------ > > What's Changed > -------------- > > * Create release 0.11.0 by [`@brahimhaddou`](https://github.com/brahimhaddou) in [graalvm/native-build-tools#746](https://redirect.github.com/graalvm/native-build-tools/pull/746) > * bump version to 0.11.1 SNAPSHOT by [`@brahimhaddou`](https://github.com/brahimhaddou) in [graalvm/native-build-tools#749](https://redirect.github.com/graalvm/native-build-tools/pull/749) > * [GR-68095] Change links in the Native Build Tools Gradle page by [`@ban-mi`](https://github.com/ban-mi) in [graalvm/native-build-tools#753](https://redirect.github.com/graalvm/native-build-tools/pull/753) > * Group annotations by dependency and print a warning if the dependency is missing by [`@dnestoro`](https://github.com/dnestoro) in [graalvm/native-build-tools#752](https://redirect.github.com/graalvm/native-build-tools/pull/752) > * Fix configuration cache compatibility in generating excluded args by [`@bacecek`](https://github.com/bacecek) in [graalvm/native-build-tools#763](https://redirect.github.com/graalvm/native-build-tools/pull/763) > * Remove the default Maven phase bound to the `metadata-copy` Maven goal to simplify the use of integration tests by [`@linghengqian`](https://github.com/linghengqian) in [graalvm/native-build-tools#748](https://redirect.github.com/graalvm/native-build-tools/pull/748) > * Prepare SBOM integration for GraalVM 25 by [`@rudsberg`](https://github.com/rudsberg) in [graalvm/native-build-tools#759](https://redirect.github.com/graalvm/native-build-tools/pull/759) > * Add testing of Gradle 9 by [`@melix`](https://github.com/melix) in [graalvm/native-build-tools#766](https://redirect.github.com/graalvm/native-build-tools/pull/766) > * supporting jdk toolchain configuration by [`@SergeDemoulinGebit`](https://github.com/SergeDemoulinGebit) in [graalvm/native-build-tools#622](https://redirect.github.com/graalvm/native-build-tools/pull/622) > * Move JUnit tests to get started by [`@ban-mi`](https://github.com/ban-mi) in [graalvm/native-build-tools#767](https://redirect.github.com/graalvm/native-build-tools/pull/767) > * Disable layered images test temporarily because of a problem on GralVM side by [`@dnestoro`](https://github.com/dnestoro) in [graalvm/native-build-tools#772](https://redirect.github.com/graalvm/native-build-tools/pull/772) > * Add new JUnit 5.14/6.0 types to initialize-at-build-time classes by [`@marcphilipp`](https://github.com/marcphilipp) in [graalvm/native-build-tools#771](https://redirect.github.com/graalvm/native-build-tools/pull/771) > * Prepare repository for release `0.11.1` by [`@dnestoro`](https://github.com/dnestoro) in [graalvm/native-build-tools#770](https://redirect.github.com/graalvm/native-build-tools/pull/770) > > New Contributors > ---------------- > > * [`@ban-mi`](https://github.com/ban-mi) made their first contribution in [graalvm/native-build-tools#753](https://redirect.github.com/graalvm/native-build-tools/pull/753) > * [`@bacecek`](https://github.com/bacecek) made their first contribution in [graalvm/native-build-tools#763](https://redirect.github.com/graalvm/native-build-tools/pull/763) > * [`@SergeDemoulinGebit`](https://github.com/SergeDemoulinGebit) made their first contribution in [graalvm/native-build-tools#622](https://redirect.github.com/graalvm/native-build-tools/pull/622) > > **Full Changelog**: <graalvm/native-build-tools@0.11.0...0.11.1> Commits * [`6545631`](graalvm/native-build-tools@6545631) Create release 0.11.1 * [`359acfb`](graalvm/native-build-tools@359acfb) Update licenses to pass style check * [`7327427`](graalvm/native-build-tools@7327427) Add changelog entries * [`73d17cc`](graalvm/native-build-tools@73d17cc) Update Reachability metadata version * [`eb52764`](graalvm/native-build-tools@eb52764) Add new JUnit 5.14/6.0 types to initialize-at-build-time classes * [`f94e6d6`](graalvm/native-build-tools@f94e6d6) Disable layered images test temporarily because of a problem on GraalVM side * [`200e23c`](graalvm/native-build-tools@200e23c) Update docs/src/docs/asciidoc/end-to-end-gradle-guide.adoc * [`079f06d`](graalvm/native-build-tools@079f06d) Move JUnit tests to get started * [`50d8fbb`](graalvm/native-build-tools@50d8fbb) supporting jdk toolchain configuration * [`77b4cfb`](graalvm/native-build-tools@77b4cfb) Add testing of Gradle 9 * Additional commits viewable in [compare view](graalvm/native-build-tools@0.11.0...0.11.1) [](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores) Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting `@dependabot rebase`. [//]: # (dependabot-automerge-start) [//]: # (dependabot-automerge-end) --- Dependabot commands and options You can trigger Dependabot actions by commenting on this PR: - `@dependabot rebase` will rebase this PR - `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it - `@dependabot merge` will merge this PR after your CI passes on it - `@dependabot squash and merge` will squash and merge this PR after your CI passes on it - `@dependabot cancel merge` will cancel a previously requested merge and block automerging - `@dependabot reopen` will reopen this PR if it is closed - `@dependabot close` will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually - `@dependabot show ignore conditions` will show all of the ignore conditions of the specified dependency - `@dependabot ignore this major version` will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this minor version` will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
Now that we are not duplicating JUnit dependencies, we could end up in a situation where:
org.junit.jupiter:junit-jupiter-params)NoClassDefFoundErrorSolution: group annotations by the dependency that introduces them, and print a warning if the dependency is not available.
Fixes: #747