Skip to content

ID3v2.3 multi-value field separator is always "/" #21

Open
@Moonbase59

Description

@Moonbase59

For some libraries, users might decide to store ID3v2.3 tags for greater compatibility with older software (as opposed to the ID3v2.4 default).

Now ID3v2.4 allows storing multiple tags of the same name (for multi-value entries like artists, genres and so on) and ID3v2.3 traditionally used a slash "/" character (which brought us the "AC/DC problem").

People (and tagging software like MusicBrainz Picard) have started to support other separators to store multiple values on one ID3v2.3 field. Typical separators used today are the semicolon ;, the vertical bar |, a comma , the NULL character \0 and even character sequences like semicolon blank ; for better readability. The underlying Mutagen supports all of these by specifying v23_sep.

This is a missing feature in MediaFile (and beets) and I’d like to add it to the MediaFile class so it could also be supported via a beets config entry:

class MediaFile(object):
    """Represents a multimedia file on disk and provides access to its
    metadata.
    """
    def __init__(self, path, id3v23=False, id3v23_sep='/'):
        """Constructs a new `MediaFile` reflecting the file at path. May
        throw `UnreadableFileError`.

        By default, MP3 files are saved with ID3v2.4 tags. You can use
        the older ID3v2.3 standard by specifying the `id3v23` option
        and (optionally) the desired separator `id3v23_sep` for
        multi-value fields (defaults to a slash character).

        To use a NULL character as terminator, pass `id3v23_sep=None`.
        """

Objections?
Would it need a u'/' instead?

N.B.: Making this a core config entry in beets should also help some plugins who currently specify their own separators.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions