MyLyrics 0.17 (1 Viewer)

mackey

Retired Team Member
  • Premium Supporter
  • May 1, 2006
    456
    177
    right there
    Home Country
    Denmark Denmark
    Hey all!

    The last couple of weeks I have improved MyLyrics in several ways. Besides several bug-fixes there has been a significantly improvement to the database, which no longer consist of a simple xml-file but now is based on binary serialization, which improves the performance greatly. Actually I should say "databases", since the music titles to which the lyrics engine has no luck in finding a matching lyric in a configuration search now are saved in their own separated database. This so called "marked database" (*) can be examined just as the lyrics database, but also be used to speed up the search for lyrics to the previously unsuccessful titles.

    (*) A title is considered "marked" when no matching lyric was found during a configuration search. If the search at a later point succesfully fetches a lyrics matching the title, that title is removed from the marked database and added to the real lyrics database.

    Though the conversion from the old xml-database to the new serialized database is easy and without any risc, it is recommended to start on a fresh, since the new database structure contains additional information (the site the lyric was found and various timestamps) that the old didn't.

    All important changes from version 0.15 to 0.17 are listed below:
    - Add: New faster binary databases
    - Add: New database containing all marked titles (*)
    - Add: Possibilities to modify both databases
    - Add: Option to only search titles contained in the marked database
    - Add: More flexible adding of lyrics files. Now possible to add multiple files and directories content.
    - Add: Option to change plugin name in MP
    - Fix: A lot of fixes to the configuration windows form and the configuration search.
    - Fix: A relative path to the xml-database in the conversion process caused problem for users of visualisations. (No more relative paths left in the code)

    Please report any issues and feature requests based on this version in this thread.
     

    Gaukaren

    Portal Member
    January 23, 2007
    41
    0
    Still has the problem where the plugin assumes that the current path is the default MediaPortal directory instead of explicitly accessing my/path/to/Mediaportal/Lyrics.xml (or whatever). This is an issue for some plugins and many visualizations (particularly Sonique ones) that change the working directory. I presume this can be fixed by substituting a relative path with the absolute one somewhere.
    Code:
    System.IO.FileNotFoundException:
    Could not find file 'C:\Program Files\Multimedia\MediaPortal\musicplayer\plugins\visualizations\Rabbit Hole 1.1\Lyrics.xml'.
    [...]
    That error is an example from trying to 'upgrade' the database. In previous versions it would just create a new Lyrics.xml whenever this situation occured.
     

    mackey

    Retired Team Member
  • Premium Supporter
  • May 1, 2006
    456
    177
    right there
    Home Country
    Denmark Denmark
    Still has the problem where the plugin assumes that the current path is the default MediaPortal directory instead of explicitly accessing my/path/to/Mediaportal/Lyrics.xml (or whatever). This is an issue for some plugins and many visualizations (particularly Sonique ones) that change the working directory. I presume this can be fixed by substituting a relative path with the absolute one somewhere.
    Code:
    System.IO.FileNotFoundException:
    Could not find file 'C:\Program Files\Multimedia\MediaPortal\musicplayer\plugins\visualizations\Rabbit Hole 1.1\Lyrics.xml'.
    [...]
    That error is an example from trying to 'upgrade' the database. In previous versions it would just create a new Lyrics.xml whenever this situation occured.
    Hi Gaukaren.
    The code of the plugin has no relative paths and no reference to the static CurrentDirectory property, and is strictly using the absolute ones from MP's MediaPortal.Configuration.Config class. This class holds the absolute adresses for the base, database, log, plugins, skin etc. directories.

    If the error you include in your post is from the latest version there is obviously a wrong absolute adress attached to the 'Base' since ....

    Ahh... you are right! I thought I had removed all relative paths but there was one left in the conversion process, which is the likely source to the error you're getting. I have made a new test-version; version 0.17. The link is in the first post of this thread.
     

    Gaukaren

    Portal Member
    January 23, 2007
    41
    0
    Ahh... you are right! I thought I had removed all relative paths but there was one left in the conversion process, which is the likely source to the error you're getting. I have made a new test-version; version 0.17. The link is in the first post of this thread.

    Almost
    peachy! This version finishes the import and generates the databases, but it leaves out the lyrics themselves from the import (only the artists and titles get in) if a troublesome viz/plugin is active.
     

    idioteque

    Retired Team Member
  • Premium Supporter
  • September 29, 2005
    609
    9
    Home Country
    Netherlands Netherlands
    importing xml with 8600 lyrics worked great, using latest SVN and .17

    2 requests:

    1:the extra space bug is still there?

    MyLyrics Start: 0 : 000.0: MyLyrics opens
    MyLyrics Stop: 0 : 000.5: MyLyrics closes
    MyLyrics Start: 0 : 013.9: MyLyrics opens
    MyLyrics Information: 0 : 013.9: findLyric(Damien Rice , 9 Crimes )
    MyLyrics Information: 0 : 013.9: LyricsOnDemand(Damien Rice , 9 Crimes )
    MyLyrics Information: 0 : 014.0: Start searchLyricWiki(Damien Rice , 9 Crimes )
    MyLyrics Information: 0 : 014.0: Lyrics007(Damien Rice , 9 Crimes )
    MyLyrics Information: 0 : 014.1: SeekLyrics(Damien Rice , 9 Crimes )

    2: when parsing the lyrics sites could you remove any HTML formatting
    , like everything including between <>


    Other than that GREAT PLUGIN and THX allot


    bit more info:

    FINDS LYRIC

    3/15/2007 7:57:08 PM Daft Punk - Daftendirekt has a match at LyricsOnDemand.
    MyLyrics Information: 0 : 409.6: findLyric(Daft Punk, Daftendirekt)


    DOES NOT FIND LYRICS

    3/15/2007 7:57:29 PM Damien Rice - 9 Crimes has a match at LyricsOnDemand.
    MyLyrics Information: 0 : 013.9: findLyric(Damien Rice , 9 Crimes )

    Why is there no extra space in config ??? but there is one in the GUI tag reader ?
     

    mackey

    Retired Team Member
  • Premium Supporter
  • May 1, 2006
    456
    177
    right there
    Home Country
    Denmark Denmark
    1:the extra space bug is still there?
    The extra spaces is caused by a small error in the MP tagreader and is not related to this plugin. hwahrmann was kind enough to promise to look at the problem, and according to the lastest changelog it seems like he has solved the problem. :) Try the next SVN and see if it fixes the problem. If not, please report to the thread that is related to the tag reader. I could fix it in the next release but it is way better to fix the problem at the source than here.

    i
    2: when parsing the lyrics sites could you remove any HTML formatting
    , like everything including between <>
    I do the best I can! ;) However the lyrics sites have multiple formatting styles that I have to parse. It is likely that another will meet a style that I haven't met in my research. It is one of the reasons why I made the new site field in the database that stores the site that the lyric was fetched from.

    When the time is right, I'll make a thread were wrongly formatted lyrics can be listed by users.
     

    idioteque

    Retired Team Member
  • Premium Supporter
  • September 29, 2005
    609
    9
    Home Country
    Netherlands Netherlands
    Great news mackey !!! I love the plugin.

    Another thing that would be great is a accept and reject button in the my lyrics GUI.

    If My Lyrics finds a lyric I can, in the gui choose whether to accept the lyric from this particular website or not and continue to search, for example if the lyrics are wrong or the formatting is all bad :)

    THx for the great suppport !!
     

    mackey

    Retired Team Member
  • Premium Supporter
  • May 1, 2006
    456
    177
    right there
    Home Country
    Denmark Denmark
    Ahh... you are right! I thought I had removed all relative paths but there was one left in the conversion process, which is the likely source to the error you're getting. I have made a new test-version; version 0.17. The link is in the first post of this thread.

    Almost
    peachy! This version finishes the import and generates the databases, but it leaves out the lyrics themselves from the import (only the artists and titles get in) if a troublesome viz/plugin is active.
    Thanks again for testing, Gaukaren. I'll fixed this issues as well, so there should be no problem in the official released 0.17 version. You should simple delete your two db-files from the database directory and you will be able to convert the xml properly.
     

    Gaukaren

    Portal Member
    January 23, 2007
    41
    0
    Thanks again for testing, Gaukaren. I'll fixed this issues as well, so there should be no problem in the official released 0.17 version. You should simple delete your two db-files from the database directory and you will be able to convert the xml properly.
    Goody. Thanks!

    I worked around the error, of course by deleting the files and temporarily setting the visualization setting to 'none' before further testing.

    This uncovered another thing, though. I don't know if this is a bug or by design: The import does not populate the 'marked' database, only a new scan not ignoring 'previously marked files' does that. You may want to run through your previous logic for detecting marked files and populate that database 'on import' as well.

    I understand your reasons for suggesting a fresh start, though some - including me, might be reluctant to loose manual tweaking and good lyrics 'left over' from the previous SOAP versions.

    Also, out of curiosity: What format are you using for the 'databases'? Why not SQLite?

    And finally, a feature request: I'd like to have an option to update a single lyric from the configuration, allowing the user to either accept or reject the change (thus being able to automagically look for a 'better' or updated lyric).
     

    mackey

    Retired Team Member
  • Premium Supporter
  • May 1, 2006
    456
    177
    right there
    Home Country
    Denmark Denmark
    I haven't paid much intention to the previously marked lyrics, but you are right that I should have either copied them into the marked database or removed them from the lyrics database. Dependending on when the next release will come I might improve the import functionality.

    I'm simple using custom binary serialization on the collection-class. It suits my demands and requirements to the database perfectly. However, I don't know much about SQLite so cannot say if that would have been a better approach. You are welcome to enlighting me. :)

    I have just started working on the feature that you and idioteque requests. It will be included in the next release.
     

    Users who are viewing this thread

    Top Bottom