Installation errors on Ubuntu 20.4

I am installing rasa 3 on ubuntu 20.4 and python 3.8.10 Have gone through the usual process of creating venv , activating it, and then ‘pip3 install rasa’. The install completes but the errors below are displayed. Also, when I do ‘pip list’ I see Rasa 3.0.4 installed.

Following is the output when I do 'rasa --version':
Traceback (most recent call last):
  File "/home/vin/rasaprojects/venv/bin/rasa", line 5, in <module>
    from rasa.__main__ import main
  File "/home/vin/rasaprojects/venv/lib/python3.8/site-packages/rasa/__main__.py", line 14, in <module>
    from rasa.cli import (
  File "/home/vin/rasaprojects/venv/lib/python3.8/site-packages/rasa/cli/export.py", line 9, in <module>
    import rasa.core.utils
  File "/home/vin/rasaprojects/venv/lib/python3.8/site-packages/rasa/core/utils.py", line 25, in <module>
    from sanic.views import CompositionView
ImportError: cannot import name 'CompositionView' from 'sanic.views' (/home/vin/rasaprojects/venv/lib/python3.8/site-packages/sanic/views.py)

@vink confirm me at the time of the installation process did you get any warnings or compatibility issues?

OR

Can you try downgrading sanic version? for me sanic==21.9.3 worked and even share the rasa --version please

pip install sanic==21.9.3

I hope this will solve your issue if it’s related to CompositionView. Good Luck!

The second screenshot shows the incompatibility errors. I installed the correct versions. Now, I am getting the following error:

rasa --version
Traceback (most recent call last):
  File "/home/vin/rasaprojects/venv/bin/rasa", line 5, in <module>
    from rasa.__main__ import main
  File "/home/vin/rasaprojects/venv/lib/python3.8/site-packages/rasa/__main__.py", line 14, in <module>
    from rasa.cli import (
  File "/home/vin/rasaprojects/venv/lib/python3.8/site-packages/rasa/cli/evaluate.py", line 7, in <module>
    from rasa.core.tracker_store import TrackerStore
  File "/home/vin/rasaprojects/venv/lib/python3.8/site-packages/rasa/core/tracker_store.py", line 22, in <module>
    from boto3.dynamodb.conditions import Key
  File "/home/vin/rasaprojects/venv/lib/python3.8/site-packages/boto3/__init__.py", line 16, in <module>
    from boto3.session import Session
  File "/home/vin/rasaprojects/venv/lib/python3.8/site-packages/boto3/session.py", line 17, in <module>
    import botocore.session
  File "/home/vin/rasaprojects/venv/lib/python3.8/site-packages/botocore/session.py", line 29, in <module>
    import botocore.credentials
  File "/home/vin/rasaprojects/venv/lib/python3.8/site-packages/botocore/credentials.py", line 35, in <module>
    from botocore.config import Config
  File "/home/vin/rasaprojects/venv/lib/python3.8/site-packages/botocore/config.py", line 16, in <module>
    from botocore.endpoint import DEFAULT_TIMEOUT, MAX_POOL_CONNECTIONS
  File "/home/vin/rasaprojects/venv/lib/python3.8/site-packages/botocore/endpoint.py", line 22, in <module>
    from botocore.awsrequest import create_request_object
  File "/home/vin/rasaprojects/venv/lib/python3.8/site-packages/botocore/awsrequest.py", line 24, in <module>
    import botocore.utils
  File "/home/vin/rasaprojects/venv/lib/python3.8/site-packages/botocore/utils.py", line 32, in <module>
    import botocore.httpsession
  File "/home/vin/rasaprojects/venv/lib/python3.8/site-packages/botocore/httpsession.py", line 10, in <module>
    from urllib3.util.ssl_ import (
ImportError: cannot import name 'PROTOCOL_TLS' from 'urllib3.util.ssl_' (/home/vin/rasaprojects/venv/lib/python3.8/site-packages/urllib3/util/ssl_.py)

@vink have you seen this video, I know it’s old but please have a look, or if you already did? Installing Rasa Open Source on Ubuntu - YouTube . I’d recommend starting with the fresh.

Thanks Nimit. Following are my steps to make the installation work.

mkdir rasa3
cd rasa3
python3 -m venv ./venv
source ./venv/bin/activate
pip3 install rasa[full]

pip3 install sanic==21.9.3
pip3 install requests==2.25.1
rasa --version
Rasa Version      :         3.0.4
Minimum Compatible Version: 3.0.0
Rasa SDK Version  :         3.0.2
Rasa X Version    :         None
Python Version    :         3.8.10
Operating System  :         Linux-5.4.0-91-generic-x86_64-with-glibc2.29
rasa init
Welcome to Rasa! 🤖

To get started quickly, an initial project will be created.
If you need some help, check out the documentation at https://rasa.com/docs/rasa.
Now let's start! 👇🏽

? Please enter a path where the project will be created [default: current directory]

@vink Great Vineet. Finally! All suggestion work for you.Can I request to please close this thread as solution for others and for your own reference please. Good Luck!