Skip to content

Commit

Permalink
a bit more bytestring handling
Browse files Browse the repository at this point in the history
  • Loading branch information
mahmoud committed Oct 3, 2024
1 parent 854ec6e commit f5139df
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions montage/loaders.py
Original file line number Diff line number Diff line change
Expand Up @@ -122,6 +122,8 @@ def load_name_list(file_obj, source='local'):

# clean up the filenames
for i, filename in enumerate(rl):
if isinstance(filename, bytes):
filename = filename.decode('utf8')
filename = filename.strip()
if filename.startswith('File:'):
filename = filename[5:]
Expand Down

0 comments on commit f5139df

Please sign in to comment.