You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
For situations like remote execution or executing in a docker container for hermiticity and reproducibility, it's helpful to keep the container image size to an absolute minimum. The bazel-generated wrapper script, which at least at the moment runs with the system-provided python3, imports a bunch of modules which are not present in the python3-minimal package in the debian ecosystem.
Describe the solution you'd like
The imports
importshutilimporttempfileimportzipfile
are only required if IsRunningFromZip is True. They shouldn't be imported if it isn't.
#42 would also solve this problem, mostly. If you have a lot of unit tests to run then the time it takes to process those often-unnecessary imports can add up.
The text was updated successfully, but these errors were encountered:
🚀 feature request
Relevant Rules
py_binary
,py_test
Description
For situations like remote execution or executing in a docker container for hermiticity and reproducibility, it's helpful to keep the container image size to an absolute minimum. The bazel-generated wrapper script, which at least at the moment runs with the system-provided
python3
, imports a bunch of modules which are not present in thepython3-minimal
package in the debian ecosystem.Describe the solution you'd like
The imports
are only required if
IsRunningFromZip
isTrue
. They shouldn't be imported if it isn't.They're imported by the template here.
The offending imports could be guarded by
in the template.
Describe alternatives you've considered
#42 would also solve this problem, mostly. If you have a lot of unit tests to run then the time it takes to process those often-unnecessary imports can add up.
The text was updated successfully, but these errors were encountered: