Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

0.17.3 failing with Error in glob: empty segment not permitted #1025

Closed
phlax opened this issue Jan 27, 2023 · 3 comments
Closed

0.17.3 failing with Error in glob: empty segment not permitted #1025

phlax opened this issue Jan 27, 2023 · 3 comments

Comments

@phlax
Copy link
Contributor

phlax commented Jan 27, 2023

🐞 bug report

Affected Rule

Trying to use rules_python at all is causing this error - but the following targets the problematic rule:

$ bazel build @python3_10_x86_64-unknown-linux-gnu//:files

Is this a regression?

Current working version is 0.16.2

Description

Update rule_python add the python_repositories() load/deps

Any use of rules_python (or python toolchain specifically) throws an error

🔬 Minimal Reproduction

🔥 Exception or Error

$ bazel build @python3_10_x86_64-unknown-linux-gnu//:files
INFO: Invocation ID: f72be4ff-6c63-486c-871d-0bf2056ac90a
ERROR: Traceback (most recent call last):
        File "/home/worker/.cache/bazel/_bazel_worker/f704bab1b165ed1368cb88f9f49e7532/external/python3_10_x86_64-unknown-linux-gnu/BUILD.bazel", line 9, column 16, in <toplevel>
                srcs = glob(
Error in glob: empty segment not permitted
ERROR: Skipping '@python3_10_x86_64-unknown-linux-gnu//:files': no such target '@python3_10_x86_64-unknown-linux-gnu//:files': target 'files' not declared in package '' defined by /home/worker/.cache/bazel/_bazel_worker/f704bab1b165ed1368cb88f9f49e7532/external/python3_10_x86_64-unknown-linux-gnu/BUILD.bazel (Tip: use `query "@python3_10_x86_64-unknown-linux-gnu//:*"` to see all the targets in that package)
WARNING: Target pattern parsing failed.
ERROR: no such target '@python3_10_x86_64-unknown-linux-gnu//:files': target 'files' not declared in package '' defined by /home/worker/.cache/bazel/_bazel_worker/f704bab1b165ed1368cb88f9f49e7532/external/python3_10_x86_64-unknown-linux-gnu/BUILD.bazel (Tip: use `query "@python3_10_x86_64-unknown-linux-gnu//:*"` to see all the targets in that package)
INFO: Elapsed time: 0.819s
INFO: 0 processes.
FAILED: Build did NOT complete successfully (0 packages loaded)

🌍 Your Environment

Operating System:

Linux

Output of bazel version:

$ bazel version
Bazelisk version: v1.11.0
Build label: 6.0.0
Build target: bazel-out/k8-opt/bin/src/main/java/com/google/devtools/build/lib/bazel/BazelServer_deploy.jar
Build time: Mon Dec 19 15:52:35 2022 (1671465155)
Build timestamp: 1671465155
Build timestamp as int: 1671465155
@alexeagle
Copy link
Contributor

Do you have the disallow_empty_glob flag enabled?
bazelbuild/bazel#8195

@phlax
Copy link
Contributor Author

phlax commented Feb 7, 2023

afaict, not explicitly from

$ git grep allow_empty_glob
# nothing returned

but im wondering if our bazel version has flipped this - seems strange noone else seems to have hit it

@phlax
Copy link
Contributor Author

phlax commented Feb 13, 2023

not sure if this was something fishy with my local env - but either way on updating to 0.18.0 everything appears to work as expected

@phlax phlax closed this as completed Feb 13, 2023
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

No branches or pull requests

2 participants