[Bug 1758537] Re: mid3v2 mangles data before adding to ID3v2 tags
Christoph Reiter
1758537 at bugs.launchpad.net
Sat Mar 24 16:00:33 UTC 2018
Thanks, that looks like a bug.
re "WXXX" vs "WXXX:" see
https://mutagen.readthedocs.io/en/latest/user/id3.html#id3-dict-
interface
--
You received this bug notification because you are a member of Ubuntu
Foundations Bugs, which is subscribed to mutagen in Ubuntu.
https://bugs.launchpad.net/bugs/1758537
Title:
mid3v2 mangles data before adding to ID3v2 tags
Status in mutagen package in Ubuntu:
New
Bug description:
I can't add frame 'WXXX' to mp3 files; mid3v2 changes the frame name
and the frame value before writing to disk.
What I did:
$ mid3v2 --list-raw example.mp3
Raw IDv2 tag info for example.mp3
TDRC(encoding=<Encoding.LATIN1: 0>, text=[u'2018'])
TALB(encoding=<Encoding.LATIN1: 0>, text=[u'albumname'])
TPE1(encoding=<Encoding.LATIN1: 0>, text=[u'artistname'])
TIT2(encoding=<Encoding.LATIN1: 0>, text=[u'songtitle'])
$ mid3v2 -h
...
You can set the value for any ID3v2 frame by using '--' and then a frame ID.
For example:
mid3v2 --TIT3 "Monkey!" file.mp3
...
$ mid3v2 --WXXX "http://ubuntu.com/" example.mp3
What I expected:
$ mid3v2 --list-raw example.mp3
WXXX(encoding=<Encoding.????: ?>, text=[u'http://ubuntu.com/'])
or
WXXX(encoding=<Encoding.????: ?>, url=u'http://ubuntu.com/')
What I saw:
$ mid3v2 --list-raw example.mp3
WXXX(encoding=<Encoding.UTF8: 3>, desc=u'', url=u"[u'http://ubuntu.com/']")
When I use mutagen itself to read that frame I get:
>>> import mutagen
>>> f = mutagen.File('example.mp3')
>>> f.tags['WXXX']
KeyError: 'WXXX'
>>> f.tags['WXXX:']
WXXX(encoding=<Encoding.UTF8: 3>, desc='', url="[u'http://ubuntu.com/']")
>>> str(f.tags['WXXX:'])
"[u'http://ubuntu.com/']"
I said "WXXX" not "WXXX:", and the value that mid3v2 stored was a string
of a one-item list of the actual string I told it to store.
ProblemType: Bug
DistroRelease: Ubuntu 17.10
Package: python-mutagen 1.38-1
ProcVersionSignature: Ubuntu 4.13.0-25.29-generic 4.13.13
Uname: Linux 4.13.0-25-generic x86_64
NonfreeKernelModules: nvidia_uvm nvidia_drm nvidia_modeset nvidia
ApportVersion: 2.20.7-0ubuntu3.7
Architecture: amd64
CurrentDesktop: XFCE
Date: Sat Mar 24 10:42:08 2018
Dependencies:
InstallationDate: Installed on 2016-06-05 (657 days ago)
InstallationMedia: Xubuntu 16.04 LTS "Xenial Xerus" - Release amd64 (20160420.1)
PackageArchitecture: all
SourcePackage: mutagen
UpgradeStatus: Upgraded to artful on 2017-10-22 (153 days ago)
To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/mutagen/+bug/1758537/+subscriptions
More information about the foundations-bugs
mailing list