Fixes#587. The disc field is only zero when there is only one medium, so I think this will do the trick. I wasn't able to reproduce the real problem within the code. This is just a small workaround.
Add three tests for the setting of tracks' medium and medium_total on
the discogs plugin. test_parse_medium_numbers_single_medium is meant
to fail due to #587.
Modify coalesce_tracks() in order to handle the case where subtracks
are defined inside an index track (as `sub_tracks` attribute),
reorganizing the if logic to avoid duplicated code.
Add a try..catch block enclosing the call to clean_tracklist, as a
measure for avoiding side effects (and reverting to just parsing the
raw_list if there are any problems).
Revise the regular expression used for extracting information from a
discogs position, making the subtrack_index only be matched if one of
the other groups is matched as well. Split the definition into several
lines in order to try to document it a bit more clearly.
Add unit tests for position parsing and non standard positions.
Fix the underscore on tox dependency.
{} is not used any more to determine the location of parameters
passed with --args.
Fix two sentences for clarity/fluidity. Display the plugin's
abilities in the intro.
Detect subtracks and merge them into a single track, taking into account
the index tracks if present. This includes a revision of the regular
expression used for converting a discogs "position" into medium, medium
index and subtrack index pieces, following the standard discogs
positions (12.2.9).
Add a first skeleton for providing unit tests for the discogs plugin,
heavily inspired by test_mb, which adds a couple of method for creating
very simple and not comprehensive Bags that mimic discogs_client.Release
and discogs_client.Track.
Add a test for checking the problem of setting media for the Tracks.
Fix a formatting problem related to sphinx not allowing spaces at the
beginning or end of an inline literal, and removed an extra sentence
at th end of the %first template function documentation.
Use a `in_argument` flag on Parser constructor for specifying if the
parser should treat commas as a special character, including the logic
in parse_expression.
Add a comparison at DateQuery.match in order to avoid comparing if the
field is not in the item.
Revise the existing types_plugin unit tests for explicitely checking the
behaviour when the values are unset.
Add ArgumentParser as a subclass of Parser that considers ARG_SEP a
special character (ie. always needs escaping, terminates a block); and
use it for parsing the substring that contains the list of arguments at
parse_argument_list().
Remove ARG_SEP from Parser.special_chars, and promote some groups of
characters used in parse_expression to class variables.
ARG_SEP is still considered an "escapable" character, pending a decision
on whether both escaped ('$,') and unescaped (',') syntax would be
allowed.
A cached completion file for faster initial completions.
Completes the following plugins: fuzzy play info lyrics fromfilename check lastgenre badfiles chroma edit smartplaylist