Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings
This repository was archived by the owner on May 8, 2026. It is now read-only.

deps: declare google-auth-library-oauth2-http#879

Closed
suztomo wants to merge 2 commits into
googleapis:maingoogleapis/java-pubsub:mainfrom
suztomo:declare_authsuztomo/java-pubsub:declare_authCopy head branch name to clipboard
Closed

deps: declare google-auth-library-oauth2-http#879
suztomo wants to merge 2 commits into
googleapis:maingoogleapis/java-pubsub:mainfrom
suztomo:declare_authsuztomo/java-pubsub:declare_authCopy head branch name to clipboard

Conversation

@suztomo

@suztomo suztomo commented Oct 18, 2021

Copy link
Copy Markdown
Member

Thank you for opening a Pull Request! Before submitting your PR, there are a few things you can do to make sure it goes smoothly:

  • Make sure to open an issue as a bug/issue before writing your code! That way we can discuss the change, evaluate designs, and agree on the general idea
  • Ensure the tests and linter pass
  • Code coverage does not decrease (if any source code was changed)
  • Appropriate docs were updated (if necessary)

Fixes #<issue_number_goes_here> ☕️

@suztomo suztomo requested review from a team October 18, 2021 18:59
@product-auto-label product-auto-label Bot added the api: pubsub Issues related to the googleapis/java-pubsub API. label Oct 18, 2021
@google-cla google-cla Bot added the cla: yes This human has signed the Contributor License Agreement. label Oct 18, 2021
@suztomo

suztomo commented Oct 18, 2021

Copy link
Copy Markdown
Member Author

@hannahrogers-google @Neenu1995 I think this will fix the potential missing com.google.auth.oauth2 package problem when a new shared dependencies BOM comes out.
googleapis/java-shared-dependencies#498 (comment)

@suztomo

suztomo commented Oct 18, 2021

Copy link
Copy Markdown
Member Author

The build is failing.

 Unused declared dependencies found:
887Warning:     com.google.auth:google-auth-library-oauth2-http:jar:1.1.0:compile

It's used here

import com.google.auth.oauth2.GoogleCredentials;

Why?

How to reproduce?

The following command fails:

mvn -B dependency:analyze -DfailOnWarning=true

@Neenu1995 Neenu1995 added the owlbot:run Add this label to trigger the Owlbot post processor. label Oct 18, 2021
@gcf-owl-bot gcf-owl-bot Bot removed the owlbot:run Add this label to trigger the Owlbot post processor. label Oct 18, 2021
The Maven analyzer plugin somehow marks the auth library unused
even though it's actually used.
googleapis#879
<ignoredUnusedDeclaredDependencies>
<ignoredUnusedDeclaredDependency>io.opencensus:opencensus-impl</ignoredUnusedDeclaredDependency>
<ignoredUnusedDeclaredDependency>javax.annotation:javax.annotation-api</ignoredUnusedDeclaredDependency>
<ignoredUnusedDeclaredDependency>com.google.auth:google-auth-library-oauth2-http</ignoredUnusedDeclaredDependency>

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Somehow I have to mark this artifact in ignoredUnusedDeclaredDependency even though it's actually used.

Screen Shot 2021-10-18 at 4 54 11 PM

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think we won't need to add an exception when compilation becomes really broken after the new release of the shared dependencies BOM.

Comment on lines +44 to +47
<dependency>
<groupId>com.google.auth</groupId>
<artifactId>google-auth-library-oauth2-http</artifactId>
</dependency>

@suztomo suztomo Oct 18, 2021

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why would this fail the "ci / dependencies"?

@hannahrogers-google hannahrogers-google added the owlbot:run Add this label to trigger the Owlbot post processor. label Oct 18, 2021
@gcf-owl-bot gcf-owl-bot Bot removed the owlbot:run Add this label to trigger the Owlbot post processor. label Oct 18, 2021
@suztomo suztomo added the kokoro:force-run Add this label to force Kokoro to re-run the tests. label Oct 19, 2021
@yoshi-kokoro yoshi-kokoro removed the kokoro:force-run Add this label to force Kokoro to re-run the tests. label Oct 19, 2021
@suztomo

suztomo commented Oct 19, 2021

Copy link
Copy Markdown
Member Author

#882 has been merged.

@suztomo suztomo closed this Oct 19, 2021
@suztomo suztomo deleted the declare_auth branch October 19, 2021 16:26
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

api: pubsub Issues related to the googleapis/java-pubsub API. cla: yes This human has signed the Contributor License Agreement.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants

Morty Proxy This is a proxified and sanitized view of the page, visit original site.