Medusa: ImportError: No module named lib2to3.pgen2.parse

Created on 23 Apr 2018  路  7Comments  路  Source: pymedusa/Medusa

Branch/Commit: Master
OS: armv5tel - python 2.7.14
What you did: First had a different error then decided to update it with the following command:

git remote set-url origin https://github.com/SickRage/SickRage.git
git fetch origin
git checkout master
git branch -u origin/master
git reset --hard origin/master
git pull

Even tried python 3.5 but didnt fix it either so switch back to python 2.7.14

What happened: Cant start up pymedusa after the update 2 days ago. Tried trouble shooting myself but gave up since my knowledge of python is limited.

What you expected: a working pymedusa

[/share/MD0_DATA/.qpkg/SickBeard-TVRage] # sh sickbeard-tvrage.sh start
armv5tel
SickBeard-TVRage prestartup checks...
 Checking for git...  Found!
Looking for /usr/bin/python2.7
Looking for /usr/local/bin/python2.7
Looking for /opt/bin/python2.7
Looking for /Apps/opt/bin/python2.7
Looking for /opt/QPython2/bin/python2.7
Found Python Version 2.7.14 at /opt/bin/python2.7
Updating SickBeard-TVRage
HEAD is now at a760263 Update translations (build 9390) [skip ci]
Already up-to-date.
Starting SickBeard-TVRage
Traceback (most recent call last):
  File "SickBeard.py", line 548, in <module>
    SickRage().start()
  File "SickBeard.py", line 250, in start
    sickbeard.initialize(consoleLogging=self.console_logging)
  File "/share/MD0_DATA/.qpkg/SickBeard-TVRage/SickBeard-TVRage/sickbeard/__init__.py", line 1316, in initialize
    if x]
ValueError: invalid literal for int() with base 10: '[]'
Fixed

Most helpful comment

All 7 comments

You changed your repo to SickRage.
Do this: https://github.com/pymedusa/Medusa/wiki/FAQ's-and-Fixes#update-problems-try-this

[/share/MD0_DATA/.qpkg/SickBeard-TVRage] # sh sickbeard-tvrage.sh start
armv5tel
SickBeard-TVRage prestartup checks...
 Checking for git...  Found!
Looking for /usr/bin/python2.7
Looking for /usr/local/bin/python2.7
Looking for /opt/bin/python2.7
Looking for /Apps/opt/bin/python2.7
Looking for /opt/QPython2/bin/python2.7
Found Python Version 2.7.14 at /opt/bin/python2.7
Updating SickBeard-TVRage
HEAD is now at 77b2091 Merge pull request #4064 from pymedusa/develop
Already up-to-date.
Starting SickBeard-TVRage
Traceback (most recent call last):
  File "SickBeard.py", line 6, in <module>
    from medusa.__main__ import main
  File "/share/MD0_DATA/.qpkg/SickBeard-TVRage/SickBeard-TVRage/medusa/__main__.py", line 88, in <module>
    from medusa.server.core import AppWebServer
  File "/share/MD0_DATA/.qpkg/SickBeard-TVRage/SickBeard-TVRage/medusa/server/core.py", line 17, in <module>
    from medusa.server.api.v1.core import ApiHandler
  File "/share/MD0_DATA/.qpkg/SickBeard-TVRage/SickBeard-TVRage/medusa/server/api/v1/core.py", line 59, in <module>
    from medusa.show.coming_episodes import ComingEpisodes
  File "/share/MD0_DATA/.qpkg/SickBeard-TVRage/SickBeard-TVRage/medusa/show/coming_episodes.py", line 39, in <module>
    from past.builtins import cmp
  File "/share/MD0_DATA/.qpkg/SickBeard-TVRage/SickBeard-TVRage/ext/past/__init__.py", line 88, in <module>
    from past.translation import install_hooks as autotranslate
  File "/share/MD0_DATA/.qpkg/SickBeard-TVRage/SickBeard-TVRage/ext/past/translation/__init__.py", line 41, in <module>
    from lib2to3.pgen2.parse import ParseError
ImportError: No module named lib2to3.pgen2.parse

The error i had before i did wrong git with the sickrage.git

@medariox Why do we need past.builtins.cmp? Isn't cmp available for both Python 2 and 3?

Same happened on Libreelec distro.
Python 2.7 on Libreelec is missing the lib2to3 module.
So, last Medusa update can't start anymore on this system.

Was this page helpful?
0 / 5 - 0 ratings