Furthermore, I can't recommend this to anyone, especially those who are using the Lyrics Reloaded (Updated) plugin, since I have no way of knowing if it even works.
It was made only because the latest version of Lyrics Reloaded (Updated) didn't work. You have an option to proceed to mess with regexes, this is the alternative that requires any basic understanding of how MusicBee plugins work. If you were able to use Lyrics Reloaded, you won't have any issues with mine.
Agreed. LyricsReloaded as a downloadable plugin doesn't actually work. Users are required to find the forum thread and look through the latest posts to try to piece together the latest version of a yaml file and manually place it in the directory, and every minor change causes it to break. Additionally, almost all of the providers that are placed in the list don't work and can't be deleted. Only people on the LyricsReloaded forum topic are used to this idea as a workable solution, but as a downloadable plugin it's ridiculous.
An API-based plugin won't have any of these issues.
Added this to https://github.com/slonopot/Beenius, thanks
Sure. Is it possible to add that as a readme to the plugin page?
MusicBee passes the data to plugins in the user-managed configurable order until the first hit. If you use LyricsReloaded, you'll have Genius and Genius via Beenius in your settings. Next, when the search is invoked, MusicBee will invoke all the providers sequentially until any valid result. You can configure multiple sources to be requested in the desired order.
That's not what occurs in my testing.
If both plugins are enabled, LyricsReloaded will only work until MusicBee is restarted, and for some reason it tries to load Genius via Beenius but fails. But after a restart, LyricsReloaded will no longer search. And even if the Genius via Beenius provider is unselected, Beenius is still used for some reason.
There's no Beenius log, so I don't know what's going on there.
2. To get rid of that popup window about loading your plugin,, I think you maybe need to implement the ReceiveNotification() function since your plugin is configured to receive startup notifications, and while I'm not sure, it seems like MusicBee might be creating that popup since nothing handled it. If I'm 100% wrong I am sorry. Haven't looked into it much.
I'll try if it'll need additional updates, the basic idea was to quickly make something that works and fill my library with lyrics. There's not much documentation to the APIs anyways.
Yeah I know, hence my caveat about really not being sure. But a quick copy-paste of ReceiveNotification() from LyricsReloaded and some minor editing might knock it out quickly.
I applaud anyone who can make a working plugin based on the state of MusicBee's non-documentation and terse Interface.
3. Highly recommend adding a logger. They are incredibly helpful for plugins, especially if people are having issues, e.g. getting results, your config file settings or whatever. Especially since it's a new plugin, people cab also refer to it to help you.
It's too simple to have any errors that aren't users. Genius might revoke the API key I've borrowed from their Android app and that's it. All the other issues are mismatches in the user library and Genius databases.
Come on now. Your plugin code may be simple, but MusicBee is not, and don't pretend it is guaranteed to be 100% bug free, especially with the proprietary allowedDistance code. If it fails for any reason, be it an application update, an unexpected input string, the Genius server being down, having a log that just outputs some information would be extremely helpful. Additionally, just knowing what it's searching for using the Beenius config would also be nice to have, especially for those really willing to tweak that config file.
There were actually a few more things I preferred to ask about, but this is getting long and it seems most important to ask about your use of your client-side auth using your token with your token insecurely used by the plugin and also it being stored in the source code repo. Kinda only getting away with it now since the plugin isn’t getting used much,-------. But it is in your public repo.
I'll look into requests if I'll see them in the first place. I've made this plugin for my own purpose and just wanted to share for the community to have an extra chance to mitigate mental damage brought by fixing the regexes in Lyrics Reloaded.
Again, the API key is a public-private anonymous one that you can easily find in the Genius Android app. It's not mine, I don't care, I'll probably move it into config anyways since it could be eventually revoked.
Ah, I didn't realize there was an anonymous one like that, my apologies. If at all configurable, probably a good idea. I would get my own token for this plugin.