Closed laur89 closed 8 years ago
Those port numbers are the outgoing ports that ncmcpp is using, which is picked at random within a given range by the kernel as ncmcpp doesn't specify a source port.
Atm it appears to be related to two different aspects: a) the request limit needs to be brought from 1000 down to ~50; b) soundcloud.py.get_user_liked() should look something like this:
def get_user_liked(self):
likes = []
liked = self._get('e1/me/likes.json?limit=50')
for data in liked:
track = data['track']
if track:
parsed_track = self.parse_track(track)
pl = data['playlist']
if parsed_track:
likes.append(parsed_track)
if pl:
likes.append((pl['title'], str(pl['id'])))
return likes
Otherwise there's good chance that parse_track() returns empty array, thus creating problems, since empty element is pushed to likes. There's also some uri parsing issue for some tracks:
File "/usr/lib/python2.7/dist-packages/mopidy/backend/__init__.py", line 164, in play
self.change_track(track)
File "/usr/lib/python2.7/dist-packages/mopidy/backend/__init__.py", line 177, in change_track
self.audio.set_uri(track.uri).get()
AttributeError: 'list' object has no attribute 'uri'
Parts of this is fixed by #69. If the other parts are still an issue, please open a new issue.
This sound more like ncmpcpp issue really, but can't quite believe it. Fetcing likes list causes ncmpcpp to crash with the following message in console, leaving terminal instance unusable:
mopidy log looks okay to me. It appears to be successful fetching the tracks. Could it be related to fact the likes list is somewhat largeish, totaling ~370 items? Playing small sets has no issues whatsoever.
Note: hand-patched the changes introduced by 461ef6c08be277f3348a13e187a881afd3c9d4c6 and ac137b270a89c097360738ee87d2c66422b23817
full log @ http://pastebin.com/Sicnuw45
On an unrelated note, is it normal that mopidy is detecting connections all over the 48XXX port range? After launching mopidy. it prints information about new mpd connections every second: