Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

acousticbrainz: refactor plugin #2251

Merged
merged 9 commits into from
Nov 20, 2016
Merged

acousticbrainz: refactor plugin #2251

merged 9 commits into from
Nov 20, 2016

Commits on Nov 20, 2016

  1. acousticbrainz: Initial cleanup

    nath@home committed Nov 20, 2016
    Configuration menu
    Copy the full SHA
    1963b52 View commit details
    Browse the repository at this point in the history
  2. acousticbrainz: Refactor the json handling part

    nath@home committed Nov 20, 2016
    Configuration menu
    Copy the full SHA
    7a67640 View commit details
    Browse the repository at this point in the history
  3. acousticbrainz: remove redundant comments

    nathdwek@laptop committed Nov 20, 2016
    Configuration menu
    Copy the full SHA
    3979619 View commit details
    Browse the repository at this point in the history
  4. acousticbrainz: log fetched attributes and values as info

    nathdwek@laptop committed Nov 20, 2016
    Configuration menu
    Copy the full SHA
    324c671 View commit details
    Browse the repository at this point in the history
  5. acousticbrainz: rewrite _map_dict_to_scheme:

    * Less lazy names
    * Separate root function from childs more naturally
    * Actually use defaultdict
    nathdwek@laptop committed Nov 20, 2016
    Configuration menu
    Copy the full SHA
    1d972b9 View commit details
    Browse the repository at this point in the history
  6. acousticbrainz: Add unit tests

    nath@home committed Nov 20, 2016
    Configuration menu
    Copy the full SHA
    4586e2d View commit details
    Browse the repository at this point in the history
  7. acousticbrainz: Test _map_data_to_scheme with real data

    nathdwek@laptop committed Nov 20, 2016
    Configuration menu
    Copy the full SHA
    5124324 View commit details
    Browse the repository at this point in the history
  8. acousticbrainz: drop DefaultList, be explicitly careful

    * I don't see DefaultList be really helpful in many other cases, so having
      a beets.util.collections module (which could also conflict with the collections
      module from standard library) with only that in it is a little silly.
    * It was elegant and concise, but there are implementation issues: it is not
      recommended to subclass builtin types, but the alternatives differ between python
      2 and 3 (subclass sequence or container or collections.abc?), moreover,
      interpreters can differ in the way they map syntaxic sugar to magic functions.
    * Also, slicing and negative indexing could do weird things, so the class wouldn't
      be really intuitive and simple at the same time
    nathdwek@laptop committed Nov 20, 2016
    Configuration menu
    Copy the full SHA
    eb1ea61 View commit details
    Browse the repository at this point in the history
  9. acousticbrainz: latest adjustments

    * Readability and consistency
    * Better logging: warn by default for attributes that were not found,
      but don't drown user with info when everything is going well.
    nath@home committed Nov 20, 2016
    Configuration menu
    Copy the full SHA
    147ced9 View commit details
    Browse the repository at this point in the history