Import error in new installation

Hi all,

We just set up the LMS for our NGO and we seem to be having an error as illustrated below, I’d appreciate all the help I can get to fix this:

ImportError: cannot import name '__app__' from 'tutor.__about__' (/home/tutor/.local/lib/python3.8/site-packages/tutor/__about__.py)

Thank you kindly.

What command are you running? What is the full stacktrace? How did you install tutor?

Thank you for your response.

I am trying to access the terminal from https://domain:3737 and this happens when I have SSH’d into the server and used sudo su tutor to run any command such as tutor local quickstart. I installed Tutor using the one click install on AWS.

Below is the stacktrace:

Traceback (most recent call last):
  File "/usr/local/bin/tutor", line 5, in <module>
    from tutor.commands.cli import main
  File "/home/tutor/.local/lib/python3.8/site-packages/tutor/commands/cli.py", line 9, in <module>
    from .android import android
  File "/home/tutor/.local/lib/python3.8/site-packages/tutor/commands/android.py", line 3, in <module>
    from .. import config as tutor_config
  File "/home/tutor/.local/lib/python3.8/site-packages/tutor/config.py", line 4, in <module>
    from . import env
  File "/home/tutor/.local/lib/python3.8/site-packages/tutor/env.py", line 10, in <module>
    from . import plugins
  File "/home/tutor/.local/lib/python3.8/site-packages/tutor/plugins/__init__.py", line 11, in <module>
    from . import v0, v1
  File "/home/tutor/.local/lib/python3.8/site-packages/tutor/plugins/v0.py", line 11, in <module>
    from tutor.__about__ import __app__
ImportError: cannot import name '__app__' from 'tutor.__about__' (/home/tutor/.local/lib/python3.8/site-packages/tutor/__about__.py)

Your installation of tutor is broken.

This line indicates that you are running tutor < 12.0.0:

(proof)

But this line implies that you are running tutor >= 13.2.0:

(proof)

You must have done something very wrong during the installation of tutor… I suggest you upgrade to the latest release.

Thank you for your assistance.

I have updated the Tutor instance, however, when running local quickstart, I get the following:

Configuration saved to /home/tutor/.local/share/tutor/config.yml
Error rendering template apps/nginx/cms.conf
Error: Missing configuration value: 'ACTIVATE_CMS' is undefined

Your installation of tutor is broken, as indicated by the fact that it refers to ACTIVATE_CMS which is an old setting. I have no idea how you got there. I suggest you uninstall tutor and install it again:

pip uninstall tutor
sudo pip uninstall tutor
which tutor # this should return nothing. if it does, you should delete the corresponding location
pip freeze | grep tutor # this should return nothing. if it does, run `pip uninstall tutor` again.
pip install --uprade tutor[full]

Thank you for your assistance @regis.

The only problem I am facing is being unable to access the server on port 3737 after having followed the above steps. Any pointers?