diff --git a/beets/util/m3u.py b/beets/util/m3u.py index 6a6aca4b5..75468c0fa 100644 --- a/beets/util/m3u.py +++ b/beets/util/m3u.py @@ -15,7 +15,7 @@ """Provides utilities to read, write an manipulate m3u playlist files.""" -from beets.util import syspath +from beets.util import syspath, normpath class EmptyPlaylistError(Exception): @@ -70,6 +70,6 @@ class M3UFile(): if not self.media_list: raise EmptyPlaylistError contents = header + self.media_list - with open(syspath(self.path), "w", encoding="utf-8") as playlist_file: + with open(syspath(normpath(self.path)), "w", encoding="utf-8") as playlist_file: playlist_file.writelines('\n'.join(contents)) playlist_file.write('\n') # Final linefeed to prevent noeol file. diff --git a/beetsplug/convert.py b/beetsplug/convert.py index 9493a5fc2..b77b9dfa2 100644 --- a/beetsplug/convert.py +++ b/beetsplug/convert.py @@ -483,7 +483,8 @@ class ConvertPlugin(BeetsPlugin): # media file paths to be unicode. Additionally we use relative # paths to ensure readability of the playlist on remote # computers. - self._log.info("Creating playlist file: {0}", playlist) + self._log.info("Creating playlist file: {0}", + util.normpath(playlist)) items_paths = [ util.syspath(item.destination( basedir=dest, path_formats=path_formats, fragment=True