Can anybody help me ?
I have made some modifications to the original plugin, so that you can specify a list of Words (feat., with, & etc.) which should be used as split.
I also made a check so it only splits if there is more than one ArtistID assigned to the track/album to avoid it splitting https://musicbrainz.org/artist/05088a61-5588-4892-82e6-337e57096a43.
It should be possibly to modify my modification to always replace the spilt Words with an & in the brackets.
I will post my version of the plugin when I come home.
This is the modified version af “Feat. artist in title”-plugin.
You can specify a list of words you want to split on and it only do the split if there is more than one artistid.
PLUGIN_NAME = 'Feat. Artists & More in Titles'
PLUGIN_AUTHOR = 'Lukas Lalinsky, Michael Wiencek, Bryan Toth, Brian Altenburg'
PLUGIN_DESCRIPTION = 'Move "feat.", "with" etc. from artist names to album and track titles. Match is case insensitive.'
PLUGIN_VERSION = "0.4"
PLUGIN_API_VERSIONS = ["0.9.0", "0.10", "0.15", "0.16", "2.0", "2.1", "2.2"]
from picard.metadata import register_album_metadata_processor, register_track_metadata_processor
import re
list = ['feat.', 'with']
def move_album_featartists(album, metadata, release):
if metadata["musicbrainz_albumartistid"].count(";") > 0:
for item in list:
_item_re = re.compile(r"([\s\S]+) "+item+" ([\s\S]+)", re.IGNORECASE)
match = _item_re.match(metadata["albumartist"])
if match:
metadata["albumartist"] = match.group(1)
metadata["album"] += " ("+item+" %s)" % match.group(2)
def move_track_featartists(album, metadata, release, track):
if metadata["musicbrainz_artistid"].count(";") > 0:
#album.tagger.log.error("BRS")
for item in list:
_item_re = re.compile(r"([\s\S]+) "+item+" ([\s\S]+)", re.IGNORECASE)
match = _item_re.match(metadata["artist"])
if match:
metadata["artist"] = match.group(1)
metadata["title"] += " ("+item+" %s)" % match.group(2)
register_album_metadata_processor(move_album_featartists)
register_track_metadata_processor(move_track_featartists)
If you want it to always be “feat.” instead of “&” or “with” or whatever you specified in the list-variable, you should change the following line:
metadata["title"] += " ("+item+" %s)" % match.group(2)
to
metadata["title"] += " (feat. %s)" % match.group(2)
Hi
Sorry , i didn’t see that you answered to me.
Thank you very much for taking time to resolve my wish !
I would never have been able to make what you made
But unfortunately, it did not work, when I add the plugin on MusicBrainz, nothing happens, nothing is added in the list of plugins.
Did you tried it with your computer ? I tried to change things, but I didn’t succeed. Maybe I did a mistake when I created the file, so for the file that I made you can download it here and maybe i have done a mistake:
https://mega.nz/#!EwtwGJYD!WjxlRDlABafFK9IzRtnQNHlG8-v_0-N49_bwVDdoiVQ
Thank you very much again
The formatting in the original post by @Gitrian was broken. I took the freedom to edit the post and fix the code formatting, so now you should be able to copy and paste it properly
Thank you very muuuch !
Everything’s working
Thank you to Gitrian for making the plugin and thank you to outsidecontext for correcting problems
It works exactly like I wanted
I put a download link here, I don’t know if it will help anyone, but maybe it will be easier like this
https://mega.nz/#!J1VARagI!9pKS7sXiXjrDNoc-gW6tPA2E1ITdK8QBb7xg9p_cFmA
And I have a last questionn it has not relevance but, it’s something I would like too, I don’t know if we have to create a plugin to do that, because it’s only a little thing:
When an artist is called by his first name and surname (exemple: Michael Jackson), the album artist sort order and the artist order is “surname, first name” (exemple: Jackson, Michael), but I would prefer if the first name was before the surname, is there any way to change it ? If someone know can he told me ? But if it’s too complicated I will create a new topic
Thank you again for the other problem you two
See this thread.
And yeah, in general please start a new topic when you have a new question. It helps other people with the same question find the answer
Ok ! Next time I will create a new topic
Thank you for the link, I didn’t find it when I searched… and it work, thank you
I really like this, good work all
Hi team, thanks for taking the time to post your code, this place is awesome!!
I’m wanting to achieve the same thing as the original poster however when I tried to copy the code into the scripting area of MusicBrain but getting “Unexpected character ‘s’ at position 41, line 15.”
Any help is apprecieated as I’d love to get this working soon
FYI - using Mac OSX 10.1.3 with version 1.4.1
The code is a plugin and not a tagger script. You have to put the code into a file with the .py extension, e.g. artistintitle.py, and put that file in Picard’s plugin folder. If everything went fine you will see the plugin in Picard’s options where you can enable it.
Hello!
I found this very useful. I have only one problem in renaming the ones with ‘&’. If the artists are two it works fine. If the artists are more than two they come with ‘,’ Here’s an example:
Beyoncé, Missy Elliott, MC Lyte & Free - Fighting Temptation becomes
Beyoncé, Missy Elliott, MC Lyte - Fighting Temptations (Feat. Free)
Is there any chance to have
Beyoncé - Fighting Temptations (Feat. Missy Elliott, MC Lyte & Free)?
Thank you
Does this work anymore? I’m running v2.2.1 now and cant even get it to show up in the list of plugins once i’ve added the .py to the plugins folder
Basically same answer as in Categorizing lossless music could work.
On a quick glance I don’t see anything that should prevent this plugin from working after this change. Just try it. If there is an error take a look at the Error/Debug log and post the errors here.
Ok went into the options panel->Open Plugin Folder
Tried both a .py and .zip in C:\Users\XXX\AppData\Local\MusicBrainz\Picard\plugins clicking on Install Plugin. Neither does anything. No response after clicking ok, doesnt appear in the list, clicked reload to no effect and restarted picard to no effect. Code is exactly as above pasted into notepad and saved as .py and then zipped.
I recall having problems installing last.fm.ng around 8 months ago getting the same nil response on anything
Ok i tried putting the .py in my D:\Downloads folder and installing from there. Now i get an error in Picard:
An error occured while loading the plugin ‘Feat. Artists & More in Titles’:
Plugin ‘Feat. Artists & More in Titles’ from ‘C:\Users\Karl\AppData\Local\MusicBrainz\Picard\plugins\Feat. Artists & More in Titles.py’ is not compatible with this version of Picard.
followed by
The plugin ‘Feat. Artists & More in Titles’ is not compatible with this version of Picard.
Guess its dead
It should still work, but you need to extend the PLUGIN_API_VERSIONS like this:
["0.9.0", "0.10", "0.15", "0.16", "2.0", "2.1", "2.2"]
See also the discussion for Categorizing lossless music - #6 by outsidecontext
Sorry, I was not quite clear about this in my first post. Since you had basically the same question as in the other thread at around the same time I for some reason assumed you had also put in the question on the other thread.
Yes!! It works again. Thanks again @outsidecontext im getting tonnes of help on this forum
My Picard settings are looking like a work of art now
Sorry to dig this up again but it looks like the plugin has stopped working again.
I updated the PLUGIN_API_VERSIONS to current i.e.:
PLUGIN_API_VERSIONS = [“0.9.0”, “0.10”, “0.15”, “0.16”, “2.0”, “2.1”, “2.2”, “2.6.4”]
2.6.4 being the version im on…
Installed the updated .py and nothing. It appears in the plugin list, is activated but doesn’t do anything
Any ideas anyone?
Ok disregard, i got the plugin working again by editing the .py to include
PLUGIN_API_VERSIONS = [“0.9.0”, “0.10”, “0.15”, “0.16”, “2.0”, “2.1”, “2.2”, “2.6.4”]
and then installing from my D:\downloads folder to let Picard decide where it wants it to live
It seems the plugin has its limitations since there are a few occurrences where tracks with multiple artists that the plugin does not detect and put into title as a featured artist. I’ve been manually correcting these items, hopefully it wont find too many of these going forward