-
Notifications
You must be signed in to change notification settings - Fork 67
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
Lombok dependency is exposed to consumers #768
Comments
The lombok annotation processor should be placed in the provided scope, so its dependency is not propagated to projects that depend on spring-content. Fixes paulcwarren#768
The lombok annotation processor should be placed in the provided scope, so its dependency is not propagated to projects that depend on spring-content. For projects where lombok is only used in tests, it is placed in the test scope. Fixes paulcwarren#768
Thanks @vierbergenlarsm, ah thanks. I think this was an oversight on my part. I believe the dependency should be at provided scope for maven. I'll look into it. |
I have already provided a PR (#769) that puts lombok in the provided scope and adds the dependency to the tests where it was previously transitively included. In some places, lombok is used for the main sources too, so there it is placed in the provided scope. |
Thanks Lars |
Describe the bug
Some spring-content components have a dependency on lombok that is exposed to downstream consumers.
Since lombok is only used at compile-time to generate additional code and consumers do not have to care about this dependency, it should not be exposed downstream.
To Reproduce
Steps to reproduce the behavior:
Expected behavior
Lombok is not present on the compile- or runtime classpath of my application that uses spring-content.
Additional context
Snippet from the compile dependencies of my project, which depends on
spring-content-rest-boot-starter
Note the indirect dependency on lombok, through the dependencies
spring-content-rest-boot-starter -> spring-content-rest -> spring-content-commons -> lombok
.I ran in to this issue because I am using Gradle for my spring-content project, where there is a separation between compile classpath and annotation-processors classpath. The lombok annotations did not result in an error during compilation because they were on the compile classpath, but the annotation processor did not run either, because lombok was not on the annotation-processor classpath.
The text was updated successfully, but these errors were encountered: