Skip to content
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

Guava's Maven dependencies are suddenly extensive #2932

Closed
shs96c opened this issue Aug 31, 2017 · 5 comments
Closed

Guava's Maven dependencies are suddenly extensive #2932

shs96c opened this issue Aug 31, 2017 · 5 comments

Comments

@shs96c
Copy link

shs96c commented Aug 31, 2017

Animal Sniffer and Error Prone would seem to be compile-time dependencies. JSR305 isn't needed at runtime either, particularly from Find Bugs. Previously, guava had no additional runtime dependencies, which is one of the things that made it attractive.

@jbduncan
Copy link
Contributor

Related issues: #2824, #2721.

I personally agree that these dependencies shouldn't be needed at all for any other than compile time, but those issues seem to point out that certain people had problems with that arrangement, so the Guava team decided to accommodate them.

@shs96c
Copy link
Author

shs96c commented Sep 1, 2017

What a pity that maven doesn't have a mechanism for saying "this dependency is needed at compile time, but not at runtime"

@shs96c shs96c closed this as completed Sep 1, 2017
@jgangemi
Copy link

jgangemi commented Sep 5, 2017

it does...you can use <optional>true</optional> on the dependency.

https://maven.apache.org/guides/introduction/introduction-to-optional-and-excludes-dependencies.html

consumers who need the dep at runtime still need to declare it.

@kashike
Copy link

kashike commented Sep 5, 2017

@jgangemi 0e29934

@jgangemi
Copy link

jgangemi commented Sep 9, 2017

mmm - should have read those related issues first as well. still seems incorrect to add those deps and then require ppl to explicitly exclude them but this isn't the place to continue that conversation.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants