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

Errors when directory / file names contain unicode characters

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Normal Normal
    • 1.4
    • 1.3.2
    • Other
    • None
    • Windows

      When a directory or file containing unicode characters in the name is loaded by Picard with debug logging on, then the following error is issued:

      Traceback (most recent call last):
        File ".\picard\tagger.py", line 315, in event
          event.run()
        File ".\picard\util\thread.py", line 34, in run
          self.func(*self.args, **self.kwargs)
        File ".\picard\log.py", line 116, in _stderr_receiver
          sys.stderr.write(formatted_log_line(level, time, msg + os.linesep))
        File "C:\Program Files (x86)\Python2\lib\encodings\cp850.py", line 12, in encode
          return codecs.charmap_encode(input,errors,encoding_map)
      UnicodeEncodeError: 'charmap' codec can't encode character u'\u2010' in position 77: character maps to <undefined>

      This is due to the log.debug statements using %s placeholder instead of %r.

            sophist Sophist
            sophist Sophist
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved:

                Version Package
                1.4