problem
problem copied to clipboard
api-guardian "soft dependency"
When using the library without depending on org.apiguardian:apiguardian-api
, on compilation several warnings will occur:
unknown enum constant Status.STABLE
unknown enum constant Status.MAINTAINED
Description
The api-guardian (introduced in #58) isn't listed as mandatory dependency for the library. Actually, it isn't even mentioned in the README. So, when using the lib as documented one will encounter said warnings on compilation.
Expected Behavior
Either make the dependency mandatory, or at least mention it in the README.
Actual Behavior
Warnings will occur on compilation.
Your Environment
- Version used: 0.26.0
Can you share a sample project where I can see those warnings?
I haven't seen those before.
I can try to create a minimal example, since I can't share the code I'm working on
i managed to reproduce it fairly simply, please have a look here: https://github.com/floriankoch0360/zalando-problem-demo when running gradle :build the warning occurs in this case, the warning is already hinting at the issue, I'm not sure sure why this isn't the case in my real project
you can uncomment the line 21 in build.gradle to fix the warning
Looks like JUnit themselves switched to compile dependencies to get around those warnings: https://stackoverflow.com/questions/46702273/warning-unknown-enum-constant-status-stable
@floriankoch0360 Care to create a PR to remove the specific scope for that dependency (implicitly making it compile)?
I created the PR, currently totally untested: https://github.com/zalando/problem/pull/342 I had the hope CI would handle testing for me, however workflow execution must be approved first
since https://github.com/zalando/problem/pull/342 was merged, this can be closed now 👍🏻