Adding a lyric source

To discuss development of addons / skins / customization of MediaMonkey.

Moderators: jiri, drakinite, Addon Administrators

fizzjob
Posts: 417
Joined: Fri Mar 30, 2007 12:37 pm

Re: Adding a lyric source

Post by fizzjob »

TIV73 wrote: Mon Aug 30, 2021 12:38 pm Try this.
- Create a new folder called lyricSourceDummy in [MM5 Installation directory]/Scripts/
- Clone or download the lyrics search dummy addon from this repo
- Put all the files in the newly created folder. The path to your info.json should be [MM5 Installation directory]/Scripts/lyricSourceDummy/info.json
- Restart mediamonkey
- Open the properties of a track
- Navigate to the Lyrics tab and press the magnifier icon in the top right corner

If everything is set up correctly, you should get a js alert telling you that the dummy addon has been loaded. If you inspect the lyricsSearch.js file, you should see all code that was defined in the lyricsSearch_add.js file of the addon.
That got it! Using that as a template I have created a lyricSourceGenius folder and it works. Now it's just packaging the addon. Thanks for the help!

edit: ...and it's submitted! First time ever doing anything with node.js and npm. I'm learning all around today! :D
Image
TIV73
Posts: 229
Joined: Sat Nov 12, 2011 1:31 pm

Re: Adding a lyric source

Post by TIV73 »

Congratulations on your first addon!
drakinite
Posts: 965
Joined: Tue May 12, 2020 10:06 am
Contact:

Re: Adding a lyric source

Post by drakinite »

fizzjob wrote: Fri Sep 03, 2021 1:44 pm edit: ...and it's submitted! First time ever doing anything with node.js and npm. I'm learning all around today! :D
Congrats; great work! However, before I can approve it: You forgot to fix that one error I pointed out earlier. The addon breaks when lyrics cannot be found, because you need to call requestNext() on line 16. :slight_smile:

On the Submit Addon page, you should be able to edit the submitted version by clicking on Version Information on the right, then selecting a new file like so: http://files.drakinite.net/2021-09-03_15-58-51.mp4
Image
Student electrical-computer engineer, web programmer, part-time MediaMonkey developer, full-time MediaMonkey enthusiast
I uploaded many addons to MM's addon page, but not all of those were created by me. "By drakinite, Submitted by drakinite" means I made it on my own time. "By Ventis Media, Inc., Submitted by drakinite" means it may have been made by me or another MediaMonkey developer, so instead of crediting/thanking me, please thank the team. You can still ask me for support on any of our addons.
fizzjob
Posts: 417
Joined: Fri Mar 30, 2007 12:37 pm

Re: Adding a lyric source

Post by fizzjob »

TIV73 wrote: Fri Sep 03, 2021 2:03 pm Congratulations on your first addon!
Well, not my first, but my first for MM5. ;)
drakinite wrote: Fri Sep 03, 2021 3:04 pm Congrats; great work! However, before I can approve it: You forgot to fix that one error I pointed out earlier. The addon breaks when lyrics cannot be found, because you need to call requestNext() on line 16. :slight_smile:

On the Submit Addon page, you should be able to edit the submitted version by clicking on Version Information on the right, then selecting a new file like so: http://files.drakinite.net/2021-09-03_15-58-51.mp4
Fixed and submitted, thanks for the reminder.
Image
drakinite
Posts: 965
Joined: Tue May 12, 2020 10:06 am
Contact:

Re: Adding a lyric source

Post by drakinite »

Approved! :slight_smile:
Image
Student electrical-computer engineer, web programmer, part-time MediaMonkey developer, full-time MediaMonkey enthusiast
I uploaded many addons to MM's addon page, but not all of those were created by me. "By drakinite, Submitted by drakinite" means I made it on my own time. "By Ventis Media, Inc., Submitted by drakinite" means it may have been made by me or another MediaMonkey developer, so instead of crediting/thanking me, please thank the team. You can still ask me for support on any of our addons.
jess12345
Posts: 23
Joined: Mon Dec 21, 2020 4:00 am

Re: Adding a lyric source

Post by jess12345 »

Been testing this add-on Tonight... Finding alot of lyrics I couldn't get before so thanks mate!! But it seems to not be grabbing all the lyrics, just part of them... But good job for your first add-on bro. I can't do anything like that so just wanted to say good job.
IanRTaylorUK
Posts: 536
Joined: Fri Dec 27, 2019 4:41 pm

Re: Adding a lyric source

Post by IanRTaylorUK »

Looks like a really useful add-on.

I have previously used Lyricator in MMW4 and so only have a few MP3 left without lyrics.

I tried the add-on but not finding lyrics - probably because there aren't any.

However, one thing I am not certain about. Is this add-on intended to be used on a single selection or cannot it be used to multi-select?
Ian Taylor
Zonky
Posts: 246
Joined: Thu Aug 26, 2010 6:39 am

Re: Adding a lyric source

Post by Zonky »

IanRTaylorUK wrote: Sat Sep 04, 2021 3:53 pm However, one thing I am not certain about. Is this add-on intended to be used on a single selection or cannot it be used to multi-select?
I've recently asked this question and was advised that this is not the case and there is no intention to do this since this might violate the websites policies for mass grabbing lyrics which will probably lead to a lockout of MM.

MM4 did not care about this, so I guess it's just a matter of time until MM5 will give us a bulk update of lyrics again. Otherwise the current lyrics feature is not very convenient...
IanRTaylorUK
Posts: 536
Joined: Fri Dec 27, 2019 4:41 pm

Re: Adding a lyric source

Post by IanRTaylorUK »

Thanks Zonky,

So I am better to use Lyricator with MMW4 for block updating with it 11(?) websites than looking up individual files with 7 sources.
Ian Taylor
Zonky
Posts: 246
Joined: Thu Aug 26, 2010 6:39 am

Re: Adding a lyric source

Post by Zonky »

drakinite wrote: Fri Sep 03, 2021 4:47 pm Approved! :slight_smile:
Guess I've found a bug when seeking for lyrics for the below mp3 file.
Genius returns in this case:

Code: Select all

[Verse 1]
<a href="/4794116/London-grammar-nightcall/Im-giving-you-a-nightcall-to-tell-you-how-i-feel-im-gonna-drive-you-through-the-night-down-the-hills-im-gonna-tell-you-something-you-dont-want-to-hear-im-gonna-show-you-where-its-dumped-but-have-no-fear" class="ReferentFragment__ClickTarget-oqvzi6-0 evuxZm
MP3 properties:

Code: Select all

Title: "Nightcall (Raaja Bones & Fyfe Dangerfield Remix)"
Artists: "London Grammar"
Album: "Nightcall"
Album Artists: "London Grammar"
Do you need more details for investigation if all?
Peke
Posts: 17446
Joined: Tue Jun 10, 2003 7:21 pm
Location: Earth
Contact:

Re: Adding a lyric source

Post by Peke »

Hi,
Are you using 5.0.2.2500 beta as in that version all HTML tags should be stripped.
Best regards,
Peke
MediaMonkey Team lead QA/Tech Support guru
Admin of Free MediaMonkey addon Site HappyMonkeying
Image
Image
Image
How to attach PICTURE/SCREENSHOTS to forum posts
Zonky
Posts: 246
Joined: Thu Aug 26, 2010 6:39 am

Re: Adding a lyric source

Post by Zonky »

Peke wrote: Tue Sep 07, 2021 8:08 pm Hi,
Are you using 5.0.2.2500 beta as in that version all HTML tags should be stripped.
Yes, I do!

Can I debug this at the time the lyrics get fetched? As mentioned above, I'm running the beta, debug version, so I assume the Chrome console should do the job, right.

Did not try it myself because of lack of some information how to debug inside MM.
Ludek
Posts: 4945
Joined: Fri Mar 09, 2007 9:00 am

Re: Adding a lyric source

Post by Ludek »

Zonky
Posts: 246
Joined: Thu Aug 26, 2010 6:39 am

Re: Adding a lyric source

Post by Zonky »

So, still no success with the above given track and Genius lyrics search :(
Still getting some html code mixed with the lyrics itselft.

I tried to debug this after noticing I need Chrome installed (running exclusively Firefox) to get the debug running :D
Nevertheless I added a breakpoint in source helpers\lyricsSearch.js at line ~986

Code: Select all

rGenius.host = 'https://genius.com/%artist%-%title%-lyrics';
After opening the tracks' properties I switched to Lyrics tab and executed the lyrics search. I assumed it stops at the line I previously added a breakpoint - but it didn't.

So any hint available how I could stop at the time lyrics search is running or better when Genius search gets called? FYI it does not stop either when setting up a breakpoint at any line in lyricsSearch.js.

Of course Genius as a source for lyrics lookup is active in settings.
Zonky
Posts: 246
Joined: Thu Aug 26, 2010 6:39 am

Re: Adding a lyric source

Post by Zonky »

So, I still want to debug this and still no solution for the Chrome debugger not stopping at the point of interest...

Anyone has got any hint for me?
Post Reply