Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Disambiguation not working with custom fields #1775

Closed
Joshfindit opened this issue Dec 28, 2015 · 12 comments
Closed

Disambiguation not working with custom fields #1775

Joshfindit opened this issue Dec 28, 2015 · 12 comments
Labels
needinfo We need more details or follow-up from the filer before this can be tagged "bug" or "feature."

Comments

@Joshfindit
Copy link

I have two copies of an album:

  • Original CD ( 1995 )
  • Remastered HDTracks release (2014 )

By default, I use $year in the folder name, so I thought a good workaround might be to create a mastering field and use it (beets modify mastering=HDTracks album year:2014 which is very handy syntax).
It set successfully, but now I can't figure out how to disambiguate with it.

path:

default: $albumartist/$albumartist - $album [$year]%aunique{,albumtype mastering year label catalognum albumdisambig}/%if{$multidisc,Disc $disc/}$track $artist - $title

beet move results in album [1995]_no such field 'mastering'_

@sampsyo sampsyo added the needinfo We need more details or follow-up from the filer before this can be tagged "bug" or "feature." label Dec 28, 2015
@sampsyo
Copy link
Member

sampsyo commented Dec 28, 2015

Hmm; yes, I can see how this would get into trouble if only some albums have the field. Can you check whether this works if you add that field to all of the albums that need to be disambiguated? Some could have an empty string, or something like "none," but this might work as-is as long as there are no actual missing values.

@Joshfindit
Copy link
Author

Ran beet modify mastering=Unknown_mastering (success), then ran beets modify mastering=HDTracks album year:2014 again (success), then did move album and got the same thing: folders suffixed with [2014]_no such field 'mastering'_

@Joshfindit
Copy link
Author

I did also notice that beet info doesn't show the mastering field. I double-checked to make sure they were set by doing beet list mastering:HDTracks and did get back the single album. Maybe the inability to see the custom field is related?

@sampsyo
Copy link
Member

sampsyo commented Dec 28, 2015

Cool; thanks for trying. I actually think the info issue is unrelated—it seems to be a problem with %aunique itself.

I just pushed a change that might fix this problem. Could you please clone the latest source and see if it works?

@Joshfindit
Copy link
Author

I git-cloned, then did ./beet move album, but it didn't make any changes.
Testing more thoroughly, it no longer did [2014]_no such field 'mastering'_, but did not use mastering as a disambiguation label.

For example, I did %aunique{,albumtype mastering albumdisambig}, and the files were moved to album [1995] 133

@sampsyo
Copy link
Member

sampsyo commented Dec 29, 2015

Hmm; that's too bad. This kind of thing can be hard to debug.

Can you show the metadata for all the albums involved? For example, something like:

beet ls -af $path $albumartist $album $albumtype $mastering $albumdisambig

for the relevant albums.

@Joshfindit
Copy link
Author

Info mildly redacted:

/Volumes/Music/beets/Ani DiFr*nco/Ani DiFr*nco - Not a Pretty Girl [1995] [RBR007-D] Ani DiFr*nco Not a Pretty Girl album $mastering 
/Volumes/Music/beets/Ani DiFr*nco/Ani DiFr*nco - Not a Pretty Girl [2014] [] Ani DiFr*nco Not a Pretty Girl album $mastering 

@sampsyo
Copy link
Member

sampsyo commented Dec 29, 2015

Hmm; so they're both missing a value for $mastering according to this output?

@Joshfindit
Copy link
Author

Correct, but when I run

beet list mastering:HDTracks

It returns the remastered album

@sampsyo
Copy link
Member

sampsyo commented Dec 29, 2015

Ah, the key is that -a flag—you'll need to modify (and inspect) albums, not individual tracks. Try beet modify -a and beet list -a.

@Joshfindit
Copy link
Author

In retrospect, that's so obvious. I've been trying to disambiguate albums by using track metadata.
Set it with -a and it worked as expected. Lesson learned. :)

@sampsyo
Copy link
Member

sampsyo commented Dec 29, 2015

Wonderful! ✨

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
needinfo We need more details or follow-up from the filer before this can be tagged "bug" or "feature."
Projects
None yet
Development

No branches or pull requests

2 participants