Skip to content

fix(bigtable): resolve project from client_options.credentials_file - #18926

Open
mutianf wants to merge 2 commits into
bigtable-accelfrom
fix-credentials-file-project
Open

mutianf wants to merge 2 commits into
bigtable-accelfrom
fix-credentials-file-project

Conversation

@mutianf

@mutianf mutianf commented Oct 30, 2026

Copy link
Copy Markdown
Contributor

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> 🦕

When project and credentials are omitted and client_options.credentials_file is set, resolve project from environment variables or credentials_file before ClientWithProject.__init__ falls back to ambient ADC.
@mutianf
mutianf requested a review from a team as a code owner October 30, 2026 16:23
@mutianf
mutianf added this pull request to stack #18928 October 30, 2026 16:23

@gemini-code-assist gemini-code-assist Bot left a comment

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.

Code Review

This pull request updates both the asynchronous and synchronous Bigtable data clients to resolve the project ID from a specified credentials file when the project and credentials are not explicitly provided. It also adds comprehensive unit tests to verify this resolution behavior under different environments. The review feedback correctly identifies potential runtime NameError issues in both clients due to a missing google.auth import, and suggests a minor style improvement to remove redundant parentheses in the synchronous client's conditional check.

This branch has not been deployed

No deployments
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

Successfully merging this pull request may close these issues.

1 participant