A7F / mtg-telegram-assistant

telegram bot to enhance your local Magic: The Gathering playgroup experience
7 stars 6 forks source link

AttributeError: module 'base64' has no attribute 'decodestring' #8

Open pawelorzech opened 1 year ago

pawelorzech commented 1 year ago

Hi there!

I wanted to install it and the issue I'm currently having is that whenever I try to turn it on, I'm getting this:

root@DietPi:/mnt/DC6C0E8F6C0E651C/MTGBot/mtg-telegram-assistant# python3 main.py Traceback (most recent call last): File "/mnt/DC6C0E8F6C0E651C/MTGBot/mtg-telegram-assistant/main.py", line 12, in <module> import tasks File "/mnt/DC6C0E8F6C0E651C/MTGBot/mtg-telegram-assistant/tasks.py", line 4, in <module> import feedparser, tables File "/usr/local/lib/python3.9/dist-packages/feedparser.py", line 93, in <module> _base64decode = getattr(base64, 'decodebytes', base64.decodestring) AttributeError: module 'base64' has no attribute 'decodestring'

What fixed this is:

sed -i 's/base64.decodestring/base64.decodebytes/g' /usr/local/lib/python3.9/dist-packages/feedparser.py

FYI, because decodestring is depricated. Hope that if someone has this issue finds this!:)