Skip to content

[Python] Add typing_extensions dep to aio Bazel target#42001

Closed
ssam18 wants to merge 3 commits into
grpc:masterfrom
ssam18:fix-aio-typing-extensions-dep
Closed

[Python] Add typing_extensions dep to aio Bazel target#42001
ssam18 wants to merge 3 commits into
grpc:masterfrom
ssam18:fix-aio-typing-extensions-dep

Conversation

@ssam18

@ssam18 ssam18 commented Apr 3, 2026

Copy link
Copy Markdown
Contributor

The aio py_library target in src/python/grpcio/grpc/BUILD.bazel was missing @typing_extensions in its deps. This causes a ModuleNotFoundError: No module named 'typing_extensions' at import time for any Bazel build that pulls in grpc.aio.

The server target already has this dep declared correctly and this just brings aio in line with the same pattern.

@ssam18

ssam18 commented Apr 3, 2026

Copy link
Copy Markdown
Contributor Author

Could someone with triage access add the 'release notes: yes' label? The label validator is blocking the CI checks.

@asheshvidyut asheshvidyut added kokoro:run release notes: yes Indicates if PR needs to be in release notes labels Apr 29, 2026
@asheshvidyut asheshvidyut self-assigned this Apr 29, 2026
@asheshvidyut

Copy link
Copy Markdown
Member

/gemini review

@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 the src/python/grpcio/grpc/BUILD.bazel file to include @typing_extensions as a dependency for the aio Python library. I have no feedback to provide.

@asheshvidyut

Copy link
Copy Markdown
Member

@ssam18 The CI is failing, please check. I think we need to update code at some more places.

https://source.cloud.google.com/results/invocations/28b219dd-4a1b-4223-a21e-9c0d59933882

ssam18 added 3 commits May 1, 2026 07:17
The aio py_library target was missing @typing_extensions in its deps,
causing a ModuleNotFoundError when importing grpc.aio in Bazel builds.
Fixes grpc#41998
The init_test and outside_init_test files import typing_extensions
but the BUILD target didn't declare it as a dep, causing the Bazel
Python tests to fail in hermetic environments.
Master renamed the typing_extensions repo to grpc_typing_extensions
in PR grpc#41713 to fix bzlmod naming consistency. Update the aio and
tests_aio/unit deps to use the new label.
@asheshvidyut asheshvidyut force-pushed the fix-aio-typing-extensions-dep branch from 9d5d680 to 7cac07e Compare May 1, 2026 01:48

@asheshvidyut asheshvidyut left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

LGTM.

Thanks for your contribution.

@copybara-service copybara-service Bot closed this in 2bd7768 May 4, 2026
asheshvidyut pushed a commit to a-detiste/grpc that referenced this pull request Jun 10, 2026
The `aio` py_library target in `src/python/grpcio/grpc/BUILD.bazel` was missing `@typing_extensions` in its deps. This causes a `ModuleNotFoundError: No module named 'typing_extensions'` at import time for any Bazel build that pulls in `grpc.aio`.

The `server` target already has this dep declared correctly and this just brings `aio` in line with the same pattern.

Closes grpc#42001

COPYBARA_INTEGRATE_REVIEW=grpc#42001 from ssam18:fix-aio-typing-extensions-dep 7cac07e
PiperOrigin-RevId: 909856306
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

lang/Python release notes: yes Indicates if PR needs to be in release notes

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants