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鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

Heads up: setuptools contain files with whitespaces in their names #617

Closed
abravalheri opened this issue Feb 3, 2022 · 2 comments
Closed

Comments

@abravalheri
Copy link

abravalheri commented Feb 3, 2022

Hello, I would like to thank the authors, maintainers and all contributors for making such a cool project 馃槃

The reason why I was brought here is that recently we received a issue in the setuptools repository (pypa/setuptools#3072) that seems related to the fact that bazel does not support whitespaces in file names, and this might generate problems for people using rules_python.

As noted in of the issue's comment, even before the recent changes, setuptools already had files containing whitespaces.

My main objective here is just to give you guys a heads up, so you are aware about potential problems that might arise. (I understand that it might be a very complicated problem to solve and that it will take a long time...)

For the time being setuptools' lead developer have kindly provided a patch with a workaround, but it is difficult to guarantee that in the future other files containing whitespace in their names will not be added (specially via vendored dependencies).

@hrfuller
Copy link
Contributor

Thanks for reaching out @abravalheri. In rules python we ignore files from installed packages that have spaces in them, which is what caused the runtime error with the Lorem file. We are aware of the issue but there ins't much we can do without upstream support for input files with spaces in bazel bazelbuild/bazel#4327

@mchristen-astranis
Copy link

mchristen-astranis commented Jan 26, 2024

Thanks for reaching out @abravalheri. In rules python we ignore files from installed packages that have spaces in them, which is what caused the runtime error with the Lorem file. We are aware of the issue but there ins't much we can do without upstream support for input files with spaces in bazel bazelbuild/bazel#4327

@hrfuller out of curiosity, where does rules_python ignore files with spaces in them. I'm noticing an issue where there's a directory of an installed package with spaces in it and that is causing a failure.

Actually, I found it here:

"**/* *", # Bazel does not support spaces in file names.

Seems like we'd want to glob exclude directories as well

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

3 participants