Uploaded image for project: 'Picard'
  1. Picard
  2. PICARD-644

UnicodeDecodeError when trying to load files with badly encoded filenames

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: Normal Normal
    • None
    • 1.3, 1.4
    • File Move & Rename
    • None

      At http://dynamikken.dk/post/13634895308/dynamikken-mens-vi-venter-ep you can download a release in the form of a .zip file with some MP3s in it. Unzipping this and trying to load it in Picard gives me:

      E: 15:00:39 Traceback (most recent call last):
        File "/usr/lib/python2.7/site-packages/picard/util/thread.py", line 46, in run
          result = self.func()
        File "/usr/lib/python2.7/site-packages/picard/tagger.py", line 373, in get_files
          root, dirs, files = walk.next()
        File "/usr/lib/python2.7/os.py", line 296, in walk
          for x in walk(new_path, topdown, onerror, followlinks):
        File "/usr/lib/python2.7/os.py", line 286, in walk
          if isdir(join(top, name)):
        File "/usr/lib/python2.7/posixpath.py", line 80, in join
          path += '/' + b
      UnicodeDecodeError: 'ascii' codec can't decode byte 0xe5 in position 12: ordinal not in range(128)
      

      Trying to load the individual files with errors in them (03, 04, 05, 07, 08), I get an error like this:

      Traceback (most recent call last):
        File "/usr/lib/python2.7/site-packages/picard/log.py", line 115, in _stderr_receiver
          sys.stderr.write(formatted_log_line(level, time, msg + os.linesep))
        File "/usr/lib/python2.7/site-packages/picard/log.py", line 106, in formatted_log_line
          msg = "%s %s" % (time.toString(timefmt), message)
      UnicodeDecodeError: 'ascii' codec can't decode byte 0xc3 in position 1237: ordinal not in range(128)
      'Traceback (most recent call last):
      File "/usr/lib/python2.7/site-packages/picard/util/thread.py", line 46, in run
        result = self.func()
      File "/usr/lib/python2.7/site-packages/picard/formats/id3.py", line 197, in _load
        file = self._File(encode_filename(filename), ID3=compatid3.CompatID3)
      File "/usr/lib/python2.7/site-packages/mutagen/_file.py", line 38, in __init__
        self.load(filename, *args, **kwargs)
      File "/usr/lib/python2.7/site-packages/mutagen/id3/__init__.py", line 1010, in load
        self.tags = ID3(filename, **kwargs)
      File "/usr/lib/python2.7/site-packages/picard/formats/mutagenext/compatid3.py", line 70, in __init__
        super(CompatID3, self).__init__(*args, **kwargs)
      File "/usr/lib/python2.7/site-packages/mutagen/id3/__init__.py", line 88, in __init__
        super(ID3, self).__init__(*args, **kwargs)
      File "/usr/lib/python2.7/site-packages/mutagen/_util.py", line 196, in __init__
        super(DictProxy, self).__init__(*args, **kwargs)
      File "/usr/lib/python2.7/site-packages/mutagen/_tags.py", line 16, in __init__
        self.load(*args, **kwargs)
      File "/usr/lib/python2.7/site-packages/mutagen/id3/__init__.py", line 132, in load
        self._fileobj = open(filename, \'rb\')
      IOError: [Errno 2] Ingen s\xc3\xa5dan fil eller filkatalog: \'/tmp/freso-tmp/Dynamikken - Mens vi venter EP/03 Jeg tror p det.mp3\'
      '
      

            Unassigned Unassigned
            freso Freso
            Votes:
            2 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:

                Version Package