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

Some hyphen from MusicBrainz are the wrong hyphen #2839

Closed
jones1008 opened this issue Mar 12, 2018 · 4 comments
Closed

Some hyphen from MusicBrainz are the wrong hyphen #2839

jones1008 opened this issue Mar 12, 2018 · 4 comments

Comments

@jones1008
Copy link

Problem

In some releases/release groups/artists/recordings (etc....) there is the following hyphen -> Unicode: (U+2010)

but it should be the following hyphen -> Unicode: (U+002D)

-

example: Third Eye Blind - Semi-Charmed Life

This can lead to some problems with plugins when searching in other databases than MusicBrainz.

possible solution

I know that this is a MusicBrainz database mistake but it could be replaced within the beets code before writing a tag to an item.
maybe like this:
tag = tag.replace("‐", "-")

But since I don't know where to add this code I am asking here...

@sampsyo
Copy link
Member

sampsyo commented Mar 12, 2018

Hello! If you think data is wrong in MusicBrainz, that's the right place to fix it—you can read up on MB's style guidelines and make edits there. (But I think you may find that they actually recommend dashes, not hyphens, in cases where that's typographically correct. Reading the Chicago Manual of Style might also help. 😃)

If you prefer ASCII hyphens over proper dashes, you can change that in your down database with beet modify. Or see #488 for a proposal that would help with automatically replacing these characters in tags.

@sampsyo sampsyo closed this as completed Mar 12, 2018
@lbesnard
Copy link

lbesnard commented Feb 2, 2021

@sampsyo I would like to comment on this, but happy to lodge a new issue but as it seems to be the same, I decided to add it here as it could also help someone else like I.

I'm importing this artist named "-M-" . However, to cd to the artist folder, I have to do the following
cd `echo -e '\u2010'm'\u2010'

Definitely not practical.

I tried to go around the issue by adding the following lines in my beet config (see http://unicode.scarfboy.com/?s=%E2%80%90):

replace:                                                                                                                                                                   
    b'\xe2\x80\x90': '-'                                                                      
    u'\u2010': '-' 

However after doing a beet move, i get

beet move albumartist:"-M-"
Moving 0 items (11 already in place).

I'm pretty sure my unicode is probably not written the proper way

@wisp3rwind
Copy link
Member

replace:                                                                                                                                                                   
    b'\xe2\x80\x90': '-'                                                                      
    u'\u2010': '-' 

I'm pretty sure my unicode is probably not written the proper way

I don't think you should put those b and u prefixes there: The configuration file is YAML after all, not a Python source file, cf. the documentation.

@lbesnard
Copy link

lbesnard commented Feb 3, 2021

thanks, for the record the following fixed it (at least one of the three...):

replace:
    '[\xe2\x80\x90]': '-'
    '[\u2010]': '-'
    '': '-'

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants