Review Request: Make MusicBrainz tagger more accurate and easy to use

Matěj Laitl matej at laitl.cz
Sun Sep 30 13:57:52 UTC 2012


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
http://git.reviewboard.kde.org/r/105290/#review19651
-----------------------------------------------------------


Looks good, just last minor things (some of them require a bit of code redoing though).

Please also add a ChangeLog entry (under CHANGES:, on top) and following tags to commit message (description here), [1] for reference:
REVIEW: 105290
GUI: brief message for handbook editors hinting how Handbook should be updated
CCMAIL: amarok-promo at kde.org             // to notidy handbook editors
DIGEST: very brief sentence describing the change, [2] for inspiration

[1] http://techbase.kde.org/Policies/SVN_Commit_Policy#Special_keywords_in_SVN_log_messages
[2] http://dot.kde.org/2012/09/23/kde-commit-digest-22nd-july-2012


Screenshot: 
<http://git.reviewboard.kde.org//r/105290/#scomment96>
    Could be made QToolButton instead of the KDE-specific widget. (we prefer Qt things unless KDE variants have an actual advatage for the use case)
    
    Then QToolButton::DelayedPopup or QToolButton::MenuButtonPopup mode would make it possible to make a default action one-click + still allow for the other action (Expand/Collapse All).
    
    I would also make popup actions named "Expand All" instead of just "All" etc. as I found it a bit confusing, human brain apparently doesn't remember the context well.
    
    I haven't found appropriate icons for these actions, but that's not really important.


Screenshot: 
<http://git.reviewboard.kde.org//r/105290/#scomment97>
    I think you can use KIcon( "document-revert" ) for this button.


Screenshot: 
<http://git.reviewboard.kde.org//r/105290/#scomment98>
    I think you can use "toold-wizard" icon here.


src/musicbrainz/MusicBrainzTags.cpp
<http://git.reviewboard.kde.org/r/105290/#comment15647>

    I've tried the latest code and it works well, but has an usability flaw:
    
    When you are expanding the items while the dialog is still searching, the expanded items are reset to unexpanded every second or so. I believe the cause is caling begin/endResetModel() here. Please transform this to calling begin/endInsertRows as appropriate. (if you add a parent with childs at once, begin/endInsertRows() needs to be called for every level)
    
    There alo seems to be some logic to expand all items on finished search. Please move that logic to the place right after the item is added in order to improve usability.
    
    I also propose using QSortFilterProxyModel to do the sorting instead of doing it manually. It will ease calling begin/endResetModel() properly.


- Matěj Laitl


On Sept. 26, 2012, 12:26 a.m., Alberto Villa wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> http://git.reviewboard.kde.org/r/105290/
> -----------------------------------------------------------
> 
> (Updated Sept. 26, 2012, 12:26 a.m.)
> 
> 
> Review request for Amarok and Sergey Ivanov.
> 
> 
> Description
> -------
> 
> The attached patch addresses several issues and brings some improvements, listed below.
> 
> Web service 2 is now being used in place of the deprecated version 1: disc number and artist credit are now better defined. This alone required a complete rewrite of MusicBrainzXmlParser.(cpp|h).
> 
> Make track search query more complicated and let it handle some mistakes (documented in code).
> 
> As in web service 2 multiple artists (e.g., Hans Zimmer & James Newton Howard) are returned splitted (i.e., they do not have one page, but each one has its own), the "Go to Artist Page" menu button was changed to a KActionMenu to support showing a sub list.
> 
> Get track title from release information, as different releases can change track title (e.g., adding (single edit) or similar).
> 
> Instead of doing *release* requests to get album artist and year, do *release group* requests. It often means fewer requests will be done (and each one takes at least 1 second, so...).
> See http://tickets.musicbrainz.org/browse/SEARCH-214 and http://tickets.musicbrainz.org/browse/SEARCH-218
> 
> Reimplement Levenshtein distance algorithm using a more efficient version (pirated from Wikibooks as well as the current one).
> 
> Tracks without results are now listed and disabled, to let user know what results are missing. Prior to this, you had to count them by hand.
> 
> File name is shown in track tooltip. Helpful when existing tags are equivocal.
> 
> Selected results are shown in bold font to be easily spotted.
> 
> Track number, track count, disc number (when existing) and release year (first release date from the release group, actually) are now shown to help distinguish among results. This means that all the fetched information is now shown to the user.
> 
> Tracks are sorted by file name (fair choice). It's done after each insertion, but since insertions are quite sparse, it doesn't cause any performance problem.
> 
> Toolbar features "Select Best Matches" and "Deselect", the latter being new, and the former being moved here from the hidden header button. To keep it not too wide, Expand and Collapse buttons were modified to be KActionMenu. They now require two clicks, but are easier to distinguish (I always had to stop and read them to distinguish between "Collapse All" and "Collapse Chosen", for example), so the time needed to click them looks mostly the same as before.
> 
> The progress bar now gets to 100% even if MusicDNS search is disabled.
> 
> All releases per track are processed instead of only the best one. I'll explain better. Each track is associated to several releases. In current code, all the releases are parsed, but only the one with the highest score is returned to the dialog. This excludes lots of good results. Now, all of them can be returned. This obviously can increase the number of returned resuts, but that's acceptable given that, before, you were not able to tag a lot of tracks. Also, two following paragraphs are about two features that mitigate this "problem".
> 
> Tracks with the same visible information are merged. There's no point in showing several tracks with same title, artist, album name and artist, album year, disc number, track count and track number, as the user will not be able to distinguish among them. Just merge them into only one result, keeping a list of artist, release and track IDs (they are and will be used). Also, the score is updated to reflect the higher one. The "Go to ... Page" menu buttons currently link to the top result (i.e., highest scoring) IDs, but in the future I might add support for showing a list.
> 
> A "Select Best Matches from This Album" menu button was added. It matches the top result release ID in other *unselected* results, to make album tagging much easier. Since a result might reference many release IDs (see the paragraph above), the match is done on the whole list of them. This is highly recommended over the "Select Best Matches" toolbar button.
> 
> Process MusicDNS results just like MusicBrainz ones (i.e., do not duplicate the logic). Simply, as they will not carry existing tags, they'll end up being checked only by track length.
> 
> Rewrite MusicDNS result matching method in the list view. Actually, remove it (it was checking for equal track ID, but that is a very weak method, especially after my updates), and use the matching system described above.
> 
> Make MusicBrainzTagsView implementation agnostic (i.e., never use MusicBrainzTagsItem inside it, and make use of UserRole).
> 
> Remove stale code from MusicBrainzFinder.cpp and MusicBrainzXmlParser.(cpp|h) dealing with MBID requests (talked to maintainer about this).
> 
> Move and rename methods to enhance consistency and tidyness. Source files are a bit easier to navigate now.
> 
> Adapt to global Amarok coding style.
> 
> 
> That's about it. The attached screenshot shows most of the visible updates.
> 
> Even if the patch rewrites many parts of the tagger, this work was possible only thanks to the solid foundations made by Sergey, who I thank for his work.
> 
> 
> Diffs
> -----
> 
>   src/dialogs/MusicBrainzTagger.h 5fa0271 
>   src/dialogs/MusicBrainzTagger.cpp e831ddc 
>   src/musicbrainz/MusicBrainzFinder.h db8cb05 
>   src/musicbrainz/MusicBrainzFinder.cpp cb6d122 
>   src/musicbrainz/MusicBrainzMeta.h 5cbd190 
>   src/musicbrainz/MusicBrainzTags.h f70d494 
>   src/musicbrainz/MusicBrainzTags.cpp 08d4fdf 
>   src/musicbrainz/MusicBrainzXmlParser.h 171a340 
>   src/musicbrainz/MusicBrainzXmlParser.cpp 473d27a 
> 
> Diff: http://git.reviewboard.kde.org/r/105290/diff/
> 
> 
> Testing
> -------
> 
> 
> Screenshots
> -----------
> 
> 
>   http://git.reviewboard.kde.org/r/105290/s/605/
> 
> 
> Thanks,
> 
> Alberto Villa
> 
>

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/amarok-devel/attachments/20120930/3ca64d06/attachment-0001.html>


More information about the Amarok-devel mailing list