Open gatlinnewhouse opened 7 years ago
Perhaps it'll work by changing
python .get(unicode)
to
python .encode(unicode)
Running 2to3 -w __init__.py
will fix the issue. I will submit a pull request.
Although eventually this error will occur:
Traceback (most recent call last):
File "/usr/bin/beet", line 11, in <module>
load_entry_point('beets==1.4.4', 'console_scripts', 'beet')()
File "/usr/lib/python3.6/site-packages/beets/ui/__init__.py", line 1209, in main
_raw_main(args)
File "/usr/lib/python3.6/site-packages/beets/ui/__init__.py", line 1196, in _raw_main
subcommand.func(lib, suboptions, subargs)
File "/home/delueze/.config/beets/plugins/rymgenre/__init__.py", line 187, in rymgenre_func
genres = self._get_genre(album)
File "/home/delueze/.config/beets/plugins/rymgenre/__init__.py", line 169, in _get_genre
release = self._get_best_release(self._get_albums(album), album)
File "/home/delueze/.config/beets/plugins/rymgenre/__init__.py", line 144, in _get_best_release
print(('URL:\n %s' % albums[0]['href']))
IndexError: list index out of range
Maybe eventually this can be fixed (because of the upcoming API) since the error seems to be deriving from rateyourmusic giving back a 503 server error for requests when I run requests in the python3 shell(?).
Thanks for the interest in beets-rymgenre
!
I'm not actively maintaining the project and I don't recommend people using it for the time being. I might consider getting back to the project when/if they publish an API.
I got banned from rateyourmusic.com for a couple of months in mid-2016 for what was claimed to be an abusive use of the site through this plugin. The answer I got from Hossein Sharifi pointed out to scraping being disallowed:
RYM does not allow (and has never allowed) access via scraping or other types of scripts which access the site in an automated fashion. Please refrain from doing so until we complete our API, which is currently being developed and should be part of Sonemic.
I should've updated the README with a warning for this (and I shall do it now done in b8efd3b).
That being said, I'll try to review your PR during the weekend. I'm not a regular Python developer so I need some time to be aware of differences between Python 2. and Python 3. and of the implications of your change.