bpo-38470: compileall tests: Use a shorter path on Windows#16778
Closed
encukou wants to merge 1 commit intopython:masterfrom
Closed
bpo-38470: compileall tests: Use a shorter path on Windows#16778encukou wants to merge 1 commit intopython:masterfrom
encukou wants to merge 1 commit intopython:masterfrom
Conversation
Contributor
|
Thank you for working on this! |
Member
Author
|
The buildbot fails with this as well: https://buildbot.python.org/all/#/builders/42/builds/59 |
Member
|
The test still fails on my Windows 10 VM using my patch to disable long path support: https://bugs.python.org/issue38470#msg354636 |
Member
|
The path created by create_long_path() is smaller than the limit, but py_compile uses _write_atomic() of importlib._bootstrap_external which adds a ".xxx" suffix: With this suffix, the temporary filename is too long: 261 characters on my VM. |
Member
|
I proposed a different approach: PR #16789. |
Member
Author
|
Aha! Thank you! I'll get on it tomorrow
…On October 14, 2019 5:59:31 PM GMT+02:00, Victor Stinner ***@***.***> wrote:
The path created by create_long_path() is smaller than the limit, but
py_compile uses _write_atomic() of importlib._bootstrap_external which
adds a ".xxx" suffix:
```
# id() is used to generate a pseudo-random filename.
path_tmp = '{}.{}'.format(path, id(path))
```
With this suffix, the temporary filename is too long: 261 characters on
my VM.
--
You are receiving this because you authored the thread.
Reply to this email directly or view it on GitHub:
#16778 (comment)
--
Sent from my Android device with K-9 Mail. Please excuse my brevity.
|
Member
|
GH-16789 has been merged instead. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
I'd like to test compileall with a really deeply nested path everywhere, but I cannot reproduce the issue occuring on Windows.
This limits the maximum path depth to 20 on Windows. That's enough to test the compileall functionality.
cc @frenzymadness
https://bugs.python.org/issue38470