File tree 2 files changed +3
-3
lines changed
2 files changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -70,7 +70,7 @@ def combinable_files(data_file, data_paths=None):
70
70
if os .path .isfile (p ):
71
71
files_to_combine .append (os .path .abspath (p ))
72
72
elif os .path .isdir (p ):
73
- pattern = os .path .join (os .path .abspath (p ), f" { local } .*")
73
+ pattern = glob . escape ( os .path .join (os .path .abspath (p ), local )) + " .*"
74
74
files_to_combine .extend (glob .glob (pattern ))
75
75
else :
76
76
raise NoDataError (f"Couldn't combine from non-existent path '{ p } '" )
Original file line number Diff line number Diff line change @@ -774,8 +774,8 @@ def erase(self, parallel=False):
774
774
file_be_gone (self ._filename )
775
775
if parallel :
776
776
data_dir , local = os .path .split (self ._filename )
777
- localdot = local + ".*"
778
- pattern = os . path . join ( os . path . abspath ( data_dir ), localdot )
777
+ local_abs_path = os . path . join ( os . path . abspath ( data_dir ), local )
778
+ pattern = glob . escape ( local_abs_path ) + ".*"
779
779
for filename in glob .glob (pattern ):
780
780
if self ._debug .should ("dataio" ):
781
781
self ._debug .write (f"Erasing parallel data file { filename !r} " )
You can’t perform that action at this time.
0 commit comments