Fix crash when passing a very long cmdline argument#11404
Fix crash when passing a very long cmdline argument#11404nicoddemus merged 2 commits intopytest-dev:mainfrom
Conversation
| ) | ||
|
|
||
|
|
||
| def test_very_long_cmdline_arg(pytester: Pytester) -> None: |
There was a problem hiding this comment.
@iandonnelly I'm having trouble reproducing the original problem, this test is passing on all platforms.
Any hints?
There was a problem hiding this comment.
its possibly related to available file-systems/path types (i believe the github runners always use unc/long paths)
would it break when using a path thats not supported on all platforms (i believe >64k)
There was a problem hiding this comment.
Hmm thanks for the hint, trying now with a very large path (>100k), let's see.
There was a problem hiding this comment.
Btw anybody on linux can test this please?
>>> import errno
>>> errno.ENAMETOOLONG
38The above is on Windows; on the original report, the errno was 36 on Linux, want to confirm that's ENAMETOOLONG is indeed 36.
EDIT: nevermind, just confirmed it is indeed 36 on Linux.
There was a problem hiding this comment.
Hmm no good using >100k filenames, the test still passes.
I guess we can rely on patching then to ensure the behavior...
2fb06f2 to
6536514
Compare
|
Ready for review -- any suggestions on how to improve the approach taken here are appreciated. |
RonnyPfannschmidt
left a comment
There was a problem hiding this comment.
this one is a special kind of icky 😮💨
Fixes pytest-dev#11394 (cherry picked from commit 28ccf47)
[7.4.x] Fix crash when passing a very long cmdline argument (#11404)
Fixes #11394