Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

fix _check_filter_and_make_params() usage

The function wants an entitiy as first argument.
The usage is correct in single entitities, but wasn't in entity lists.

The problem was introduced in
86110dc
where the function parameters were changed.
That gave
TypeError: ... takes at least 2 arguments (2 give)
when using get_releases_by_discid() and others.

The problem was hidden with the fix in
4260ed5
No TypeError anymore,
but the entity was set to the includes, includes were empty in return.

For single entity requests this was fixed correctly in
088562d

This now finally fixes this for entity list requests.
  • Loading branch information...
commit 9bc221cfa03f7dbdba85f890fbf11e502da57a4d 1 parent c63e4dd
@JonnyJD JonnyJD authored
Showing with 4 additions and 4 deletions.
  1. +4 −4 musicbrainzngs/musicbrainz.py
View
8 musicbrainzngs/musicbrainz.py
@@ -734,19 +734,19 @@ def search_works(query='', limit=None, offset=None, strict=False, **fields):
# Lists of entities
def get_releases_by_discid(id, includes=[], release_status=[], release_type=[]):
- params = _check_filter_and_make_params(includes, release_status, release_type=release_type)
+ params = _check_filter_and_make_params("release", includes, release_status, release_type=release_type)
return _do_mb_query("discid", id, includes, params)
def get_recordings_by_echoprint(echoprint, includes=[], release_status=[], release_type=[]):
- params = _check_filter_and_make_params(includes, release_status, release_type)
+ params = _check_filter_and_make_params("recording", includes, release_status, release_type)
return _do_mb_query("echoprint", echoprint, includes, params)
def get_recordings_by_puid(puid, includes=[], release_status=[], release_type=[]):
- params = _check_filter_and_make_params(includes, release_status, release_type)
+ params = _check_filter_and_make_params("recording", includes, release_status, release_type)
return _do_mb_query("puid", puid, includes, params)
def get_recordings_by_isrc(isrc, includes=[], release_status=[], release_type=[]):
- params = _check_filter_and_make_params(includes, release_status, release_type)
+ params = _check_filter_and_make_params("recording", includes, release_status, release_type)
return _do_mb_query("isrc", isrc, includes, params)
def get_works_by_iswc(iswc, includes=[]):
Please sign in to comment.
Something went wrong with that request. Please try again.