Unable to build ujson

I try 5 days to install rasa x on my windows 11 laptop. i cannot do it.

Building wheel for ujson (setup.py) … error ERROR: Command errored out with exit status 1: command: ‘d:\anaconda3\python.exe’ -u -c ‘import io, os, sys, setuptools, tokenize; sys.argv[0] = ‘“’”‘C:\Users\SithumDanthanarayana\AppData\Local\Temp\pip-install-twl_330k\ujson_fe9b94f6056c4d548482abcc80f45de6\setup.py’“’”’; file=’“’”‘C:\Users\SithumDanthanarayana\AppData\Local\Temp\pip-install-twl_330k\ujson_fe9b94f6056c4d548482abcc80f45de6\setup.py’“’”’;f = getattr(tokenize, ‘“’”‘open’“’”’, open)(file) if os.path.exists(file) else io.StringIO(’“’”‘from setuptools import setup; setup()’“’”’);code = f.read().replace(’“’”’\r\n’“’”’, ‘“’”’\n’“’”’);f.close();exec(compile(code, file, ‘“’”‘exec’“’”’))’ bdist_wheel -d ‘C:\Users\SithumDanthanarayana\AppData\Local\Temp\pip-wheel-_6ly4jci’ cwd: C:\Users\SithumDanthanarayana\AppData\Local\Temp\pip-install-twl_330k\ujson_fe9b94f6056c4d548482abcc80f45de6 Complete output (14 lines): Warning: ‘classifiers’ should be a list, got type ‘filter’ running bdist_wheel running build running build_ext building ‘ujson’ extension creating build creating build\temp.win-amd64-3.8 creating build\temp.win-amd64-3.8\Release creating build\temp.win-amd64-3.8\Release\python creating build\temp.win-amd64-3.8\Release\lib C:\Program Files (x86)\Microsoft Visual Studio\2019\BuildTools\VC\Tools\MSVC\14.29.30133\bin\HostX86\x64\cl.exe /c /nologo /Ox /W3 /GL /DNDEBUG /MD -I./python -I./lib -Id:\anaconda3\include -Id:\anaconda3\include “-IC:\Program Files (x86)\Microsoft Visual Studio\2019\BuildTools\VC\Tools\MSVC\14.29.30133\include” /Tc./python/ujson.c /Fobuild\temp.win-amd64-3.8\Release./python/ujson.obj -D_GNU_SOURCE ujson.c d:\anaconda3\include\pyconfig.h(59): fatal error C1083: Cannot open include file: ‘io.h’: No such file or directory error: command ‘C:\Program Files (x86)\Microsoft Visual Studio\2019\BuildTools\VC\Tools\MSVC\14.29.30133\bin\HostX86\x64\cl.exe’ failed with exit status 2

@SithumDantha Welcome to the forum :bouquet:

Please follow these steps for the installation of ROS and Rasa X :slight_smile:

Note: You can ignore few steps, if you already performed it!

Please install Anaconda from Anaconda | Individual Edition , then create the conda environment using the following command

  1. conda create -n rasa3 python=3.8
  2. conda activate rasa 3

PS: If you using Linux, check the environment for the same.

Note: I’d recommend to create a fresh environment if not you can proceed with next steps:

Note: Downgrade pip 21 to pip version to 20.2.2(conda install pip==20.2.2)

For Rasa Open Source:

`pip install rasa==2.8.1`
`pip install rasa-sdk==2.8.1'

check version rasa --version its install or not

For Installing basic project:

rasa init

then if you need

For Rasa-X Installation

pip install rasa-x==0.39.3 --extra-index-url https://pypi.rasa.com/simple

check rasa version rasa --version its install or not

You will see some error : ImportError: cannot import name ‘RowProxy’ from ‘sqlalchemy.engine’ Install

pip install SQLAlchemy==1.3.22 should fix it

If sanic related error: pip install sanic-jwt==1.6.0

delete .db (events and rasa ) if is showing alembic issue.

If you have any error in-between please share with us.

Note: You will see the Event Loop Close error in the terminal, you can ignore that, its an persistent issue with Rasa X and team is working on it.

I hope this will solve your issue. Good Luck!

1 Like

This will get long time, but not install

@SithumDantha you are using Miniconda3, and I recommend to use Anaconda. Is it possible you can install Anaconda and follow the above steps? Or you have created the miniconda3 virtual environment? me confused.

@SithumDantha can you please briefly explain what you have done so far?

@SithumDantha Is that you following some video tutorial for installing anaconda or rasa? yes or no?

I create virtual environment. last days i follow video tutorial

@SithumDantha I can see, mean you not following my steps :frowning: please follow and you will be able to install with ease. Try a fresh approach my friend.

Note: Please dn’t follow the video tutorial and just stick with the steps and you will able to archived your goal.

1 Like

now I followed your steps

Iinstall anaconda and I did your steps, but I get this .

@SithumDantha share me proper screenshot with conda activated environment and while activating environment type rasa --version and share with me the screenshot.

1 Like

@SithumDantha Wrong, you not created the Conda environment and you install rasa directly in the base conda, please check my post: Unable to build ujson - #2 by nik202

Please create the conda environment install rasa and rasa-sdk and then install rasa x

I am here for while do it and let me know if any error exist?

@SithumDantha Note: I can see you created the rasa3 environment please activate first rasa3 and then type rasa --version and share me the screenshot

Ok?

1 Like

yes. thanks for your help

ok

@SithumDantha Cool, do it I’m here only :slight_smile: Today you will able to install rasa and rasa x both :wink:

1 Like

@SithumDantha perfect now first run the rasa init and create the default mood bot project and then talk with the bot and then /stop the bot and then install rasa x using command : pip install rasa-x==0.39.3 --extra-index-url https://pypi.rasa.com/simple

Ok?

1 Like

@SithumDantha Ok, go on and install rasa x and follow my first post! I trust you, you will able to install rasa x :slight_smile:

@SithumDantha do check is rasa x install or not using again the rasa --version command it should show rasa x version now with 0.39.3

1 Like

how long to install rasa-x? my os is windows 11.