We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent df4d16f commit b301befCopy full SHA for b301bef
rules_python_gapic/py_gapic_pkg.bzl
@@ -19,6 +19,13 @@ def _py_gapic_src_pkg_impl(ctx):
19
dir_srcs = []
20
py_srcs = []
21
for dep in ctx.attr.deps:
22
+ # Check if this is a `proto_library` dependency which has `ProtoInfo`
23
+ # See https://bazel.build/versions/6.5.0/rules/lib/ProtoInfo
24
+ if ProtoInfo in dep:
25
+ # Add `*.proto` files to the output which exist in `direct_sources`
26
+ # https://bazel.build/versions/6.5.0/rules/lib/ProtoInfo#direct_sources
27
+ for source in dep[ProtoInfo].direct_sources:
28
+ py_srcs.append(source)
29
for f in dep.files.to_list():
30
if f.is_directory:
31
dir_srcs.append(f)
0 commit comments