Antonio Larrosa f95a848c82 PICARD-1207: Fix handling paths with unicode characters on python3
When moving additional files, the call to encode_filename encodes the
path to the original filename converting the variable from str to bytes,
provoking the next exception when calling shutil, which only accepts
strings (the documentation don't specifically mention that for shutil.move,
but it does for copy, copyfile, copymode, etc.)

Traceback (most recent call last):
  File "./picard/util/thread.py", line 47, in run
    result = self.func()
  File "./picard/file.py", line 222, in _save_and_rename
    self._move_additional_files(old_filename, new_filename)
  File "./picard/file.py", line 435, in _move_additional_files
    shutil.move(old_file, new_file)
  File "/usr/x86_64-pc-linux-gnu/lib/python3.6/shutil.py", line 551, in move
    if _destinsrc(src, dst):
  File "/usr/x86_64-pc-linux-gnu/lib/python3.6/shutil.py", line 565, in _destinsrc
    if not src.endswith(os.path.sep):
TypeError: endswith first arg must be bytes or a tuple of bytes, not str

Also, other functions like os.path.dirname, os.path.isdir, os.stat,
os.utime ... allow to be passed a string, instead of the encoded path in
a bytes variable. So I removed the use of encode_filename for all cases
that either require or allow a string to be passed so we don't do
unnecessary processing neither.

I checked this fixes PICARD-1207.
2018-08-08 14:59:33 +05:30
2017-12-23 02:49:35 +05:30
2018-07-30 17:09:34 +05:30
2018-07-29 11:54:47 +05:30
2018-07-29 11:54:47 +05:30
2017-02-26 12:11:44 +01:00
2006-10-19 22:00:30 +02:00
2018-07-30 17:18:09 +05:30
2017-07-25 23:16:01 +05:30
2018-07-18 11:12:52 +05:30

MusicBrainz Picard

Travis Status Codacy Grade AppVeyor Status

MusicBrainz Picard is a cross-platform (Linux/Mac OS X/Windows) application written in Python and is the official MusicBrainz tagger.

Picard supports the majority of audio file formats, is capable of using audio fingerprints (AcoustIDs), performing CD lookups and disc ID submissions, and it has excellent Unicode support. Additionally, there are several plugins available that extend Picard's features.

When tagging files, Picard uses an album-oriented approach. This approach allows it to utilize the MusicBrainz data as effectively as possible and correctly tag your music. For more information, see the illustrated quick start guide to tagging.

Picard is named after Captain Jean-Luc Picard from the TV series Star Trek: The Next Generation.

Binary downloads are available here.

Support and issue reporting

Please report all bugs and feature requests in the MusicBrainz issue tracker. If you need support in using Picard please read the documentation first and have a look at the MusicBrainz community forums.

Description
No description provided
Readme 82 MiB
Languages
Python 99.4%
Shell 0.3%
PowerShell 0.2%
C 0.1%