Closed joharei closed 11 years ago
Gotcha; thanks for reporting this. I'll fix up the schemas this afternoon.
Alright, those searches should all work now. Want to give them another shot and let me know how it goes?
Thanks for the quick response, that works great! I have another one for you; when I search for a song that I've given a rating, I get this:
2013-08-05 21:59:25,472 - gmusicapi.Mobileclient1 (shared:269) [ERROR]: the response format for Search was not recognized.
Failed to validate field 'entries' list schema: additional property 'rating' not defined by 'properties' are not allowed in field 'track'
First, try the develop branch. If you can recreate this error with the most recent code please [create an issue](http://goo.gl/qbAW8) that includes the above ValidationException and the following request/response:
{'url': 'https://www.googleapis.com/sj/v1/query', 'headers': {'Authorization': '<omitted>'}, 'params': {'q': u'C2C - Down The Road', 'max-results': 1}, 'method': 'GET'}
'{\n "kind": "sj#searchresponse",\n "entries": [\n {\n "type": "3",\n "album": {\n "kind": "sj#album",\n "name": "Down The Road - A Tribute to C2C",\n "albumArtist": "DJ Silk",\n "albumArtRef": "http://lh5.ggpht.com/Y0rgbHf5jT1ELnfNeDs-Kv9MRYgGpmGsjOq1Qtw-riz5efpumhc7hpHYhgDVho404kqDymSO_is",\n "albumId": "B47d2w2cavo7fw6qfy7dmnqg6mm",\n "artist": "DJ Silk",\n "artistId": [\n "Awhj7l2cplqgciswr6cso7gntou"\n ],\n "year": 2012\n },\n "score": 39.82831954956055\n },\n {\n "type": "1",\n "track": {\n "kind": "sj#track",\n "title": "Down The Road",\n "artist": "C2C",\n "album": "Tetra",\n "albumArtist": "C2C",\n "year": 2012,\n "trackNumber": 2,\n "durationMillis": "207000",\n "albumArtRef": [\n {\n "url": "http://lh6.ggpht.com/smNw3gZYXHGz1r0JDgPbh99p7jN4TLBiAt7dMWREzXfxCeCYuRs0QqMhAJ8HaJglyiO-uu8S9hE"\n }\n ],\n "playCount": 1,\n "discNumber": 1,\n "rating": "5",\n "estimatedSize": "8290252",\n "trackType": "7",\n "storeId"...'
A traceback follows:
Traceback (most recent call last):
File "/usr/lib/python2.7/site-packages/gmusicapi/protocol/shared.py", line 248, in perform
cls.validate(response, parsed_response)
File "/usr/lib/python2.7/site-packages/gmusicapi/protocol/mobileclient.py", line 194, in validate
return validictory.validate(msg, cls._res_schema)
File "/usr/lib/python2.7/site-packages/validictory/__init__.py", line 31, in validate
return v.validate(data, schema)
File "/usr/lib/python2.7/site-packages/validictory/validator.py", line 559, in validate
self._validate(data, schema)
File "/usr/lib/python2.7/site-packages/validictory/validator.py", line 562, in _validate
self.__validate("_data", {"_data": data}, schema)
File "/usr/lib/python2.7/site-packages/validictory/validator.py", line 593, in __validate
newschema.get(schemaprop))
File "/usr/lib/python2.7/site-packages/validictory/validator.py", line 223, in validate_properties
properties.get(eachProp))
File "/usr/lib/python2.7/site-packages/validictory/validator.py", line 593, in __validate
newschema.get(schemaprop))
File "/usr/lib/python2.7/site-packages/validictory/validator.py", line 266, in validate_items
(fieldname, old_error), fieldname, e.value)
ValidationException: Failed to validate field 'entries' list schema: additional property 'rating' not defined by 'properties' are not allowed in field 'track'
I'd like to report a few issues related to
search_all_access()
I get this error when trying to search for something that would return no results:
Also, a very similar one when there would be exactly one song as result:
And one last error that seems to an album with various artists:
That said, I really love your project :)