What happened?
When running Gazelle on a Python target that contains
from typing import TYPE_CHECKING
if TYPE_CHECKING:
from lib.my_module import AnExampleClass
Gazelle will attempt to create a pyi_deps item of "//lib:my_module". pyi_deps is not supported in the rules_py py_library API at this time and will create a build failure.
Minimal example for repro:
https://github.com/addisonjones3/rules_py_pyi_repro
main branch fails on bazel build //...
pre-gazelle is the state prior to bazel run //:gazelle_python
Version
Development (host) and target OS/architectures: Linux amd64
Output of bazel --version: 7.7.1
Version of the Aspect rules, or other relevant rules from your
WORKSPACE or MODULE.bazel file:
bazel_dep(name = "aspect_gazelle_prebuilt", version = "0.0.24")
bazel_dep(name = "aspect_rules_py", version = "1.8.4")
Language(s) and/or frameworks involved:
How to reproduce
Clone repro repo
To verify failure:
To show Gazelle is automatically creating those deps when run:
Switch to pre-gazelle branch
bazel run //:gazelle_python & \
bazel build //...
Any other information?
No response
What happened?
When running Gazelle on a Python target that contains
Gazelle will attempt to create a
pyi_depsitem of"//lib:my_module".pyi_depsis not supported in therules_pypy_libraryAPI at this time and will create a build failure.Minimal example for repro:
https://github.com/addisonjones3/rules_py_pyi_repro
mainbranch fails onbazel build //...pre-gazelleis the state prior tobazel run //:gazelle_pythonVersion
Development (host) and target OS/architectures: Linux amd64
Output of
bazel --version: 7.7.1Version of the Aspect rules, or other relevant rules from your
WORKSPACEorMODULE.bazelfile:Language(s) and/or frameworks involved:
How to reproduce
Clone repro repo
To verify failure:
To show Gazelle is automatically creating those deps when run:
Switch to
pre-gazellebranchbazel run //:gazelle_python & \ bazel build //...Any other information?
No response