-
-
Notifications
You must be signed in to change notification settings - Fork 673
Open
Description
Bazel v9.0.0
rules_python v1.8.5
Debian 14 "forky", dockerized
During some invocations of bazel run the following warning is emitted occasionally:
WARNING: Repository '@@rules_python++python+python_3_11_x86_64-unknown-linux-gnu' will be fetched again since the file 'lib/python3.11/importlib' has been modified externally. External modifications can lead to incorrect builds.
Such sporadic warnings may not seem like much, but they wreck havoc in situations where output of bazel run command is precisely scripted. Such situation arise quite commonly in automated builds.
Some additional details:
- These are containerized builds, so filesystem state is reset after each build.
- The warning does not appear to result from immediate use of any
rules_pythonrules. In my build I invoke twobazel runcommands one after another. The first one runs the script which invokes some python rules indirectly viapkg_tar(fromrules_pkg) rule. The second one runs a binary which has no python dependencies in its dep tree whatsoever. Only this second invocation sometimes triggers the totally unexpected warning. The binary is not specific - whatever other binary I run viabazel runmay or may not trigger the warning. - I wonder if there's a way to somehow initialize the importlib thingy with a separate bazel command so that import commands don't emit any warnings.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels