Hello community, here is the log from the commit of package python-mutagen for openSUSE:Factory checked in at 2018-08-08 14:45:30 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/python-mutagen (Old) and /work/SRC/openSUSE:Factory/.python-mutagen.new (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "python-mutagen" Wed Aug 8 14:45:30 2018 rev:30 rq:627528 version:1.41.0 Changes: -------- --- /work/SRC/openSUSE:Factory/python-mutagen/python-mutagen.changes 2018-04-22 14:29:10.719682792 +0200 +++ /work/SRC/openSUSE:Factory/.python-mutagen.new/python-mutagen.changes 2018-08-08 14:45:34.520770423 +0200 @@ -1,0 +2,11 @@ +Sun Aug 5 11:08:22 UTC 2018 - adr...@suse.de + +- update to version 1.41.0: + * Documentation fixes :pr:`342` (:user:`Jakub Wilk <jwilk>`) + * mid3v2: Add support for WXXX frames :bug:`344` :bug:`348` + * Fix decoding of track_peak from MP3 Info Tag :pr:`345` + (:user:`Anton Yuzhaninov <citrin>`) + * MonkeysAudio: set bits_per_sample for older files :bug:`347` +- drop obsolete ignore-W504.patch + +------------------------------------------------------------------- Old: ---- ignore-W504.patch mutagen-1.40.0.tar.gz New: ---- mutagen-1.41.0.tar.gz ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ python-mutagen.spec ++++++ --- /var/tmp/diff_new_pack.Z4a60X/_old 2018-08-08 14:45:35.348771772 +0200 +++ /var/tmp/diff_new_pack.Z4a60X/_new 2018-08-08 14:45:35.348771772 +0200 @@ -18,7 +18,7 @@ %{?!python_module:%define python_module() python-%{**} python3-%{**}} Name: python-mutagen -Version: 1.40.0 +Version: 1.41.0 Release: 0 Summary: Python module to Handle Audio Metadata License: GPL-2.0-or-later @@ -27,8 +27,6 @@ Source: https://files.pythonhosted.org/packages/source/m/mutagen/mutagen-%{version}.tar.gz # PATCH-FIX-OPENSUSE reduce-test-length.diff alarr...@suse.com -- Reduce the number of iterations so tests don't take so long to finish Patch0: reduce-test-length.diff -# PATCH-FIX-UPSTREAM ignore-W504.patch alarr...@suse.com -- Ignore PEP8's W504 which makes tests fail -Patch1: ignore-W504.patch BuildRequires: %{python_module devel} BuildRequires: %{python_module hypothesis} BuildRequires: %{python_module pycodestyle} @@ -53,7 +51,6 @@ %prep %setup -q -n mutagen-%{version} %patch0 -p1 -%patch1 -p1 # remove shebangs from library files find mutagen/ -name "*.py" -exec sed -i -e '/^#!\s\?\/usr\/bin\/\(env\s\)\?python$/d' {} ';' ++++++ mutagen-1.40.0.tar.gz -> mutagen-1.41.0.tar.gz ++++++ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/mutagen-1.40.0/NEWS new/mutagen-1.41.0/NEWS --- old/mutagen-1.40.0/NEWS 2018-01-25 17:09:13.000000000 +0100 +++ new/mutagen-1.41.0/NEWS 2018-07-16 21:32:50.000000000 +0200 @@ -1,3 +1,13 @@ +1.41.0 - 2018-07-15 +------------------- + +* Documentation fixes :pr:`342` (:user:`Jakub Wilk <jwilk>`) +* mid3v2: Add support for WXXX frames :bug:`344` :bug:`348` +* Fix decoding of track_peak from MP3 Info Tag :pr:`345` + (:user:`Anton Yuzhaninov <citrin>`) +* MonkeysAudio: set bits_per_sample for older files :bug:`347` + + 1.40.0 - 2018-01-25 ------------------- @@ -630,7 +640,7 @@ * Bug Fixes: * FLAC: Raise IOError, instead of UnboundLocalError, when trying - to open a non-existant file. (Lukáš Lalinský, Debian #448734) + to open a non-existent file. (Lukáš Lalinský, Debian #448734) * Throw out invalid frames when upgrading from 2.3 to 2.4. * Fixed reading of Unicode strings from ASF files on big-endian platforms. diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/mutagen-1.40.0/PKG-INFO new/mutagen-1.41.0/PKG-INFO --- old/mutagen-1.40.0/PKG-INFO 2018-01-25 17:09:43.000000000 +0100 +++ new/mutagen-1.41.0/PKG-INFO 2018-07-16 21:33:14.000000000 +0200 @@ -1,6 +1,6 @@ Metadata-Version: 1.1 Name: mutagen -Version: 1.40.0 +Version: 1.41.0 Summary: read and write audio tags for many formats Home-page: https://github.com/quodlibet/mutagen Author: Michael Urman @@ -43,6 +43,7 @@ Classifier: Programming Language :: Python :: 3.4 Classifier: Programming Language :: Python :: 3.5 Classifier: Programming Language :: Python :: 3.6 +Classifier: Programming Language :: Python :: 3.7 Classifier: Programming Language :: Python :: Implementation :: CPython Classifier: Programming Language :: Python :: Implementation :: PyPy Classifier: License :: OSI Approved :: GNU General Public License v2 (GPLv2) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/mutagen-1.40.0/docs/Makefile new/mutagen-1.41.0/docs/Makefile --- old/mutagen-1.40.0/docs/Makefile 2017-05-25 15:49:20.000000000 +0200 +++ new/mutagen-1.41.0/docs/Makefile 2018-07-08 23:33:34.000000000 +0200 @@ -1,5 +1,5 @@ all: - sphinx-build -b html -n . _build + python -m sphinx -b html -n . _build clean: rm -rf _build diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/mutagen-1.40.0/docs/index.rst new/mutagen-1.41.0/docs/index.rst --- old/mutagen-1.40.0/docs/index.rst 2017-05-25 15:57:23.000000000 +0200 +++ new/mutagen-1.41.0/docs/index.rst 2018-07-08 23:33:34.000000000 +0200 @@ -66,7 +66,7 @@ considered from the start and are fully supported. * All ID3v2 versions and all ID3v2.4 frames are covered, including rare ones like POPM or RVA2. -* We take automated testing very seriously. All bug fixes are commited with a +* We take automated testing very seriously. All bug fixes are committed with a test that prevents them from recurring, and new features are committed with a full test suite. diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/mutagen-1.40.0/docs/man/mid3v2.rst new/mutagen-1.41.0/docs/man/mid3v2.rst --- old/mutagen-1.40.0/docs/man/mid3v2.rst 2017-06-14 18:44:44.000000000 +0200 +++ new/mutagen-1.41.0/docs/man/mid3v2.rst 2018-07-08 23:33:34.000000000 +0200 @@ -39,7 +39,7 @@ -e, --escape Enable interpretation of backslash escapes for tag values. - Makes it possible to escape the colon-separator in TXXX, COMM + Makes it possible to escape the colon-separator in TXXX, WXXX, COMM values like '\\:' and insert escape sequences like '\\n', '\\t' etc. -f, --list-frames @@ -107,10 +107,15 @@ added by prefixing the name of the frame with "--". For example, ``--TIT3 "Monkey!"`` will set the TIT3 (subtitle) frame to ``Monkey!``. -The TXXX frame requires a colon-separated description key; many TXXX frames -may be set in the file as long as they have different keys. To set this -key, just separate the text with a colon, e.g. ``--TXXX -"ALBUMARTISTSORT:Examples, The"``. +The TXXX frame has the format <DESCRIPTION:TEXT>; many TXXX frames may be +set in the file as long as they have different keys. To set this key, just +separate the text with a colon, e.g. ``--TXXX "ALBUMARTISTSORT:Examples, +The"``. The description can be omitted in which case it defaults to an empty +string. + +The WXXX frame has the same format as TXXX but since URLs usually contain a +":" you have provide a description or enable escaping (-e): +``--WXXX "desc:http://foo.bar"`` or ``-e --WXXX "http\\://foo.bar"`` The USLT frame has the format <DESCRIPTION:TEXT:LANGUAGE>. The language and description may be omitted, in which case the language defaults to English, diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/mutagen-1.40.0/docs/user/classes.rst new/mutagen-1.41.0/docs/user/classes.rst --- old/mutagen-1.40.0/docs/user/classes.rst 2017-05-25 15:49:20.000000000 +0200 +++ new/mutagen-1.41.0/docs/user/classes.rst 2018-07-08 23:33:34.000000000 +0200 @@ -40,7 +40,7 @@ Tags ---- -Each FileType has a attributes tags which holds a :class:`Tags` instance. The +Each FileType has an attribute tags which holds a :class:`Tags` instance. The Tags interface depends mostly on each format. It exposes a dict-like interface where the type of keys and values depends on the implementation of each format. diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/mutagen-1.40.0/docs/user/id3.rst new/mutagen-1.41.0/docs/user/id3.rst --- old/mutagen-1.40.0/docs/user/id3.rst 2017-12-28 12:33:30.000000000 +0100 +++ new/mutagen-1.41.0/docs/user/id3.rst 2018-07-08 23:33:34.000000000 +0200 @@ -16,7 +16,7 @@ audio.save() If you use the ID3 module, you should familiarize yourself with how -ID3v2 tags are stored, by reading the the details of the ID3v2 +ID3v2 tags are stored, by reading the details of the ID3v2 standard at http://id3.org/id3v2.4.0-structure. ID3 Dict Interface diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/mutagen-1.40.0/man/mid3v2.1 new/mutagen-1.41.0/man/mid3v2.1 --- old/mutagen-1.40.0/man/mid3v2.1 2017-06-14 18:44:44.000000000 +0200 +++ new/mutagen-1.41.0/man/mid3v2.1 2018-07-08 23:33:34.000000000 +0200 @@ -54,7 +54,7 @@ .TP .B \-e\fP,\fB \-\-escape Enable interpretation of backslash escapes for tag values. -Makes it possible to escape the colon\-separator in TXXX, COMM +Makes it possible to escape the colon\-separator in TXXX, WXXX, COMM values like \(aq\e:\(aq and insert escape sequences like \(aq\en\(aq, \(aq\et\(aq etc. .TP .B \-f\fP,\fB \-\-list\-frames @@ -123,10 +123,15 @@ added by prefixing the name of the frame with "\-\-". For example, \fB\-\-TIT3 "Monkey!"\fP will set the TIT3 (subtitle) frame to \fBMonkey!\fP\&. .sp -The TXXX frame requires a colon\-separated description key; many TXXX frames -may be set in the file as long as they have different keys. To set this -key, just separate the text with a colon, e.g. \fB\-\-TXXX -"ALBUMARTISTSORT:Examples, The"\fP\&. +The TXXX frame has the format <DESCRIPTION:TEXT>; many TXXX frames may be +set in the file as long as they have different keys. To set this key, just +separate the text with a colon, e.g. \fB\-\-TXXX "ALBUMARTISTSORT:Examples, +The"\fP\&. The description can be omitted in which case it defaults to an empty +string. +.sp +The WXXX frame has the same format as TXXX but since URLs usually contain a +":" you have provide a description or enable escaping (\-e): +\fB\-\-WXXX "desc:http://foo.bar"\fP or \fB\-e \-\-WXXX "http\e\e://foo.bar"\fP .sp The USLT frame has the format <DESCRIPTION:TEXT:LANGUAGE>. The language and description may be omitted, in which case the language defaults to English, diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/mutagen-1.40.0/mutagen/__init__.py new/mutagen-1.41.0/mutagen/__init__.py --- old/mutagen-1.40.0/mutagen/__init__.py 2018-01-25 17:09:13.000000000 +0100 +++ new/mutagen-1.41.0/mutagen/__init__.py 2018-07-16 21:32:50.000000000 +0200 @@ -23,7 +23,7 @@ from mutagen._file import FileType, StreamInfo, File from mutagen._tags import Tags, Metadata, PaddingInfo -version = (1, 40, 0) +version = (1, 41, 0) """Version tuple.""" version_string = ".".join(map(str, version)) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/mutagen-1.40.0/mutagen/_file.py new/mutagen-1.41.0/mutagen/_file.py --- old/mutagen-1.40.0/mutagen/_file.py 2017-05-25 15:49:20.000000000 +0200 +++ new/mutagen-1.41.0/mutagen/_file.py 2018-07-08 23:33:34.000000000 +0200 @@ -113,7 +113,7 @@ Does nothing if the file has no tags. Raises: - MutagenError: if deleting wasn't possible + mutagen.MutagenError: if deleting wasn't possible """ if self.tags is not None: @@ -150,14 +150,15 @@ """Adds new tags to the file. Raises: - MutagenError: if tags already exist or adding is not possible. + mutagen.MutagenError: + if tags already exist or adding is not possible. """ raise NotImplementedError @property def mime(self): - """A list of mime types (`text`)""" + """A list of mime types (:class:`mutagen.text`)""" mimes = [] for Kind in type(self).__mro__: @@ -171,7 +172,7 @@ """Returns a score for how likely the file can be parsed by this type. Args: - filename (path): a file path + filename (fspath): a file path fileobj (fileobj): a file object open in rb mode. Position is undefined header (bytes): data of undefined length, starts with the start of diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/mutagen-1.40.0/mutagen/_tools/mid3v2.py new/mutagen-1.41.0/mutagen/_tools/mid3v2.py --- old/mutagen-1.40.0/mutagen/_tools/mid3v2.py 2018-01-23 13:53:38.000000000 +0100 +++ new/mutagen-1.41.0/mutagen/_tools/mid3v2.py 2018-07-08 23:33:34.000000000 +0200 @@ -315,9 +315,20 @@ frame = mutagen.id3.TXXX( encoding=3, text=value, desc=desc) id3.add(frame) + elif frame == "WXXX": + for value in vlist: + values = string_split(value, ":", 1) + if len(values) == 1: + desc, value = "", values[0] + else: + desc, value = values[0], values[1] + frame = mutagen.id3.WXXX( + encoding=3, url=value, desc=desc) + id3.add(frame) elif issubclass(mutagen.id3.Frames[frame], mutagen.id3.UrlFrame): - frame = mutagen.id3.Frames[frame](encoding=3, url=vlist) + frame = mutagen.id3.Frames[frame]( + encoding=3, url=vlist[-1]) id3.add(frame) else: frame = mutagen.id3.Frames[frame](encoding=3, text=vlist) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/mutagen-1.40.0/mutagen/asf/__init__.py new/mutagen-1.41.0/mutagen/asf/__init__.py --- old/mutagen-1.40.0/mutagen/asf/__init__.py 2017-05-25 15:49:20.000000000 +0200 +++ new/mutagen-1.41.0/mutagen/asf/__init__.py 2018-07-08 23:33:34.000000000 +0200 @@ -259,7 +259,7 @@ Args: filething (filething) - padding (PaddingFunction) + padding (:obj:`mutagen.PaddingFunction`) Raises: mutagen.MutagenError """ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/mutagen-1.40.0/mutagen/flac.py new/mutagen-1.41.0/mutagen/flac.py --- old/mutagen-1.40.0/mutagen/flac.py 2017-11-04 12:18:20.000000000 +0100 +++ new/mutagen-1.41.0/mutagen/flac.py 2018-07-08 23:33:34.000000000 +0200 @@ -838,7 +838,7 @@ Args: filething (filething) deleteid3 (bool): delete id3 tags while at it - padding (PaddingFunction) + padding (:obj:`mutagen.PaddingFunction`) If no filename is given, the one most recently loaded is used. """ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/mutagen-1.40.0/mutagen/id3/_file.py new/mutagen-1.41.0/mutagen/id3/_file.py --- old/mutagen-1.40.0/mutagen/id3/_file.py 2017-05-25 15:49:20.000000000 +0200 +++ new/mutagen-1.41.0/mutagen/id3/_file.py 2018-07-08 23:33:34.000000000 +0200 @@ -223,7 +223,7 @@ the separator used to join multiple text values if v2_version == 3. Defaults to '/' but if it's None will be the ID3v2v2.4 null separator. - padding (PaddingFunction) + padding (:obj:`mutagen.PaddingFunction`) Raises: mutagen.MutagenError diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/mutagen-1.40.0/mutagen/id3/_frames.py new/mutagen-1.41.0/mutagen/id3/_frames.py --- old/mutagen-1.40.0/mutagen/id3/_frames.py 2017-06-14 18:44:44.000000000 +0200 +++ new/mutagen-1.41.0/mutagen/id3/_frames.py 2018-07-08 23:33:34.000000000 +0200 @@ -265,7 +265,7 @@ if tflags & Frame.FLAG24_COMPRESS: try: data = zlib.decompress(data) - except zlib.error as err: + except zlib.error: # the initial mutagen that went out with QL 0.12 did not # write the 4 bytes of uncompressed size. Compensate. data = datalen_bytes + data diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/mutagen-1.40.0/mutagen/monkeysaudio.py new/mutagen-1.41.0/mutagen/monkeysaudio.py --- old/mutagen-1.40.0/mutagen/monkeysaudio.py 2017-05-25 15:49:20.000000000 +0200 +++ new/mutagen-1.41.0/mutagen/monkeysaudio.py 2018-07-08 23:33:34.000000000 +0200 @@ -66,6 +66,9 @@ blocks_per_frame = 73728 else: blocks_per_frame = 9216 + self.bits_per_sample = 0 + if header[48:].startswith(b"WAVEfmt"): + self.bits_per_sample = struct.unpack("<H", header[74:76])[0] self.version /= 1000.0 self.length = 0.0 if (self.sample_rate != 0) and (total_frames > 0): diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/mutagen-1.40.0/mutagen/mp3/_util.py new/mutagen-1.41.0/mutagen/mp3/_util.py --- old/mutagen-1.40.0/mutagen/mp3/_util.py 2017-05-25 15:49:20.000000000 +0200 +++ new/mutagen-1.41.0/mutagen/mp3/_util.py 2018-07-08 23:33:34.000000000 +0200 @@ -11,6 +11,7 @@ http://wiki.hydrogenaud.io/index.php?title=MP3 """ +from __future__ import division from functools import partial from mutagen._util import cdata, BitReader @@ -37,7 +38,9 @@ """VBR quality: 0..9""" track_peak = None - """Peak signal amplitude as float. None if unknown.""" + """Peak signal amplitude as float. 1.0 is maximal signal amplitude + in decoded format. None if unknown. + """ track_gain_origin = 0 """see the docs""" @@ -123,8 +126,7 @@ self.track_peak = None else: # see PutLameVBR() in LAME's VbrTag.c - self.track_peak = ( - cdata.uint32_be(track_peak_data) - 0.5) / 2 ** 23 + self.track_peak = cdata.uint32_be(track_peak_data) / 2 ** 23 track_gain_type = r.bits(3) self.track_gain_origin = r.bits(3) sign = r.bits(1) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/mutagen-1.40.0/mutagen/ogg.py new/mutagen-1.41.0/mutagen/ogg.py --- old/mutagen-1.40.0/mutagen/ogg.py 2017-06-01 14:43:24.000000000 +0200 +++ new/mutagen-1.41.0/mutagen/ogg.py 2018-07-08 23:33:34.000000000 +0200 @@ -576,7 +576,7 @@ Args: filething (filething) - padding (PaddingFunction) + padding (:obj:`mutagen.PaddingFunction`) Raises: mutagen.MutagenError """ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/mutagen-1.40.0/setup.cfg new/mutagen-1.41.0/setup.cfg --- old/mutagen-1.40.0/setup.cfg 2017-08-10 17:26:07.000000000 +0200 +++ new/mutagen-1.41.0/setup.cfg 2018-07-08 23:33:34.000000000 +0200 @@ -6,6 +6,6 @@ mutagen/_senf/* [flake8] -ignore=E128,W601,E402,E731,W503,E741,E305,E121,E124 +ignore=E128,W601,E402,E731,W503,E741,E305,E121,E124,W504 builtins=cmp,unicode,long,xrange,basestring exclude= diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/mutagen-1.40.0/setup.py new/mutagen-1.41.0/setup.py --- old/mutagen-1.40.0/setup.py 2018-01-25 15:19:47.000000000 +0100 +++ new/mutagen-1.41.0/setup.py 2018-07-16 21:00:52.000000000 +0200 @@ -267,6 +267,7 @@ 'Programming Language :: Python :: 3.4', 'Programming Language :: Python :: 3.5', 'Programming Language :: Python :: 3.6', + 'Programming Language :: Python :: 3.7', 'Programming Language :: Python :: Implementation :: CPython', 'Programming Language :: Python :: Implementation :: PyPy', 'License :: OSI Approved :: GNU General Public License v2 (GPLv2)', diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/mutagen-1.40.0/tests/quality/test_pep8.py new/mutagen-1.41.0/tests/quality/test_pep8.py --- old/mutagen-1.40.0/tests/quality/test_pep8.py 2018-01-23 11:46:23.000000000 +0100 +++ new/mutagen-1.41.0/tests/quality/test_pep8.py 2018-07-08 23:33:34.000000000 +0200 @@ -14,10 +14,10 @@ from .util import setup_cfg try: - import pep8 as pycodestyle + import pycodestyle except ImportError: try: - import pycodestyle + import pep8 as pycodestyle except ImportError: pycodestyle = None diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/mutagen-1.40.0/tests/test_flac.py new/mutagen-1.41.0/tests/test_flac.py --- old/mutagen-1.40.0/tests/test_flac.py 2017-05-25 15:49:20.000000000 +0200 +++ new/mutagen-1.41.0/tests/test_flac.py 2018-07-08 23:33:34.000000000 +0200 @@ -572,7 +572,7 @@ def test_open_nonexistant(self): """mutagen 1.2 raises UnboundLocalError, then it tries to open - non-existant FLAC files""" + non-existent FLAC files""" filename = os.path.join(DATA_DIR, "doesntexist.flac") self.assertRaises(MutagenError, FLAC, filename) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/mutagen-1.40.0/tests/test_monkeysaudio.py new/mutagen-1.41.0/tests/test_monkeysaudio.py --- old/mutagen-1.40.0/tests/test_monkeysaudio.py 2017-05-25 15:49:20.000000000 +0200 +++ new/mutagen-1.41.0/tests/test_monkeysaudio.py 2018-07-08 23:33:34.000000000 +0200 @@ -28,6 +28,11 @@ self.failUnlessAlmostEqual(self.mac396.info.length, 3.68, 2) self.failUnlessAlmostEqual(self.mac390.info.length, 15.63, 2) + def test_bits_per_sample(self): + assert self.mac399.info.bits_per_sample == 16 + assert self.mac396.info.bits_per_sample == 16 + assert self.mac390.info.bits_per_sample == 16 + def test_version(self): self.failUnlessEqual(self.mac399.info.version, 3.99) self.failUnlessEqual(self.mac396.info.version, 3.96) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/mutagen-1.40.0/tests/test_tools_mid3v2.py new/mutagen-1.41.0/tests/test_tools_mid3v2.py --- old/mutagen-1.40.0/tests/test_tools_mid3v2.py 2017-11-05 19:55:19.000000000 +0100 +++ new/mutagen-1.41.0/tests/test_tools_mid3v2.py 2018-07-08 23:33:34.000000000 +0200 @@ -123,6 +123,65 @@ self.failUnlessEqual(frame.desc, "A\\") self.failUnlessEqual(frame.text, ["B:C"]) + def test_txxx_multiple(self): + res, out = self.call( + fsn(u"--TXXX"), fsn(u"A:B"), + fsn(u"--TXXX"), fsn(u"C:D"), + self.filename) + self.failUnlessEqual((res, out), (0, "")) + f = ID3(self.filename) + assert len(f.getall("TXXX")) == 2 + + def test_wcom(self): + res, out = self.call(fsn(u"--WCOM"), fsn(u"foo"), self.filename) + self.failUnlessEqual((res, out), (0, "")) + f = ID3(self.filename) + frames = f.getall("WCOM") + assert len(frames) == 1 + assert frames[0].url == "foo" + + def test_wcom_multiple(self): + res, out = self.call( + fsn(u"--WCOM"), fsn(u"foo"), + fsn(u"--WCOM"), fsn(u"bar"), + self.filename) + self.failUnlessEqual((res, out), (0, "")) + f = ID3(self.filename) + frames = f.getall("WCOM") + assert len(frames) == 1 + assert frames[0].url == "bar" + + def test_wxxx(self): + res, out = self.call(fsn(u"--WXXX"), fsn(u"foobar"), self.filename) + self.failUnlessEqual((res, out), (0, "")) + f = ID3(self.filename) + frames = f.getall("WXXX") + assert len(frames) == 1 + assert frames[0].url == "foobar" + + def test_wxxx_escape(self): + res, out = self.call( + fsn(u"-e"), fsn(u"--WXXX"), fsn(u"http\\://example.com/"), + self.filename) + self.failUnlessEqual((res, out), (0, "")) + f = ID3(self.filename) + frames = f.getall("WXXX") + assert frames[0].url == "http://example.com/" + + def test_wxxx_multiple(self): + res, out = self.call( + fsn(u"--WXXX"), fsn(u"A:B"), + fsn(u"--WXXX"), fsn(u"C:D"), + self.filename) + self.failUnlessEqual((res, out), (0, "")) + f = ID3(self.filename) + frames = sorted(f.getall("WXXX"), key=lambda f: f.HashKey) + assert len(frames) == 2 + assert frames[0].url == "B" + assert frames[0].desc == "A" + assert frames[1].url == "D" + assert frames[1].desc == "C" + def test_ufid(self): res, out, err = self.call2( fsn(u"--UFID"), fsn(u"foo:bar"), self.filename)