strizhechenko / bandcamp-player

Utility for streaming random music from bandcamp by specified tag via mplayer
https://pypi.python.org/pypi/bandcamp-player
MIT License
21 stars 3 forks source link

Parse fail: AttributeError: 'NoneType' object has no attribute 'find_all'` #3

Open richardmalone opened 5 years ago

richardmalone commented 5 years ago

Hi,

Love the app—it has found me some great music over the past few years.

Recently (6 months) it has stopped working. I imagine the Bandcamp API has changed, but what do I know!

This is the output:

λ bandcamp-player.exe synthwave INFO:root:request: https://bandcamp.com/tag/synthwave Traceback (most recent call last): File "C:\Users\rmalone\scoop\apps\python\current\Scripts\bandcamp-player-script.py", line 11, in <module> load_entry_point('bandcamp-player==0.2.0', 'console_scripts', 'bandcamp-player')() File "c:\users\rmalone\scoop\apps\python\3.7.4\lib\site-packages\bandcamp_player\__init__.py", line 26, in main loop() File "c:\users\rmalone\scoop\apps\python\3.7.4\lib\site-packages\bandcamp_player\__init__.py", line 16, in loop album_url = tag_data.album_random().href File "c:\users\rmalone\scoop\apps\python\3.7.4\lib\site-packages\bandcamp_parser\tag.py", line 32, in album_random albums = self.albums() File "c:\users\rmalone\scoop\apps\python\3.7.4\lib\site-packages\bandcamp_parser\tag.py", line 27, in albums results = soup.find('div', attrs={'class': 'results'}).find_all('a') AttributeError: 'NoneType' object has no attribute 'find_all'

You haven't updated this Git in ages, but if you know someone might use it again I hope you wish to renew your interest.

Regards, R

hopdebee commented 1 year ago

hi @richardmalone, you can check out https://github.com/hopdebee/bandcamp-player-evo, which has gotten rid of the python based scraping and now uses an external js library to get the album urls.