File tree Expand file tree Collapse file tree 1 file changed +6
-2
lines changed Expand file tree Collapse file tree 1 file changed +6
-2
lines changed Original file line number Diff line number Diff line change @@ -53,7 +53,7 @@ def create_long_path(self):
53
53
# It will be 100 directories deep, or shorter if the OS limits it.
54
54
for i in range (10 ):
55
55
longer_path = os .path .join (
56
- long_path , * (f"long_directory_ { i } _{ j } " for j in range (10 ))
56
+ long_path , * (f"dir_ { i } _{ j } " for j in range (10 ))
57
57
)
58
58
59
59
# Check if we can open __pycache__/*.pyc.
@@ -87,8 +87,12 @@ def create_long_path(self):
87
87
long_source = longer_source
88
88
long_cache = longer_cache
89
89
90
+ # On Windows, MAX_PATH is 260 characters, our path with the 20
91
+ # directories is 160 characters long, leaving something for the
92
+ # root (self.directory) as well.
93
+ # Tests assume long_path contains at least 10 directories.
90
94
if i < 2 :
91
- raise ValueError ('Path limit is too short' )
95
+ raise ValueError (f'"Long path" is too short: { long_path } ' )
92
96
93
97
self .source_path_long = long_source
94
98
self .bc_path_long = long_cache
You can’t perform that action at this time.
0 commit comments