Skip to content

beets 2.3 doesn't like dots in the filename patterns #5771

@cybersphinx

Description

@cybersphinx

Problem

Running beet import on any album with

paths:
    default: $albumartist/$album%aunique{}/$track. $title

in the configuration results in filenames like 01.flac, i.e. everything after the dot is missing.

Investigation

Looking for "path" in the git log brings up the very recently merged #5224, which introduced os.path.splitext in https://github.com/beetbox/beets/blob/master/beets/util/__init__.py#L767 and adding some prints for path, first_stage and second_stage shows what happens when you also change the configuration to

paths:
    default: $albumartist/$album%aunique{}/$track. $title.x.y

path is the filename without extension, first_stage removes the .y, and second_stage the .x.

Solutions?

Not sure. The above config is a workaround, adding a +suffix to the path passed to the three _legalize_stage calls kinda works but shows

Fell back to default replacements when naming file Artist/Album/01. Title.x.y. Configure replacements to avoid lengthening the filename.

Anyway, something in there expects a filename containing a dot to have an extension, but the filename used doesn't have the extension added.

Metadata

Metadata

Assignees

Labels

bugbugs that are confirmed and actionable

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions