Robot framework | jybot not recognized as internal or external command - robotframework

While executing our robot framework scripts, we get error : "jybot is not recognized as internal or external command"
Steps followed for installation:
installed python and set path in environment variables
installed jython and set path in environment variables
installed robotframework using robotframework-2.9.1.win-amd64.exe
while installing robotframework only two files were created "pybot" ,"rebot" and "robot" . We created jybot .bat file and set path of run.py file created in python\lib\site-packages\robot folder
our application has build over java swing, so we have created one wrapper file in python. we have placed everything in jython folder and trying to execute test cases.
error while execution -- jybot is not recognized as internal or external command.
could you please suggest a solution to this issue

Most probably you have not installed robotframework to jython interpreter.
Verify this by checking list of packages in jython by pip:
jython -m pip list
or checking if robot is really installed:
jython -m robot.run
If there is no pip or no robotframework package in list:
install pip to jython (easist is to download get-pip.py from web and run jython get-pip.py)
run pip from jython and install robot:
jython -m pip install robotframework

Related

Command "jupyter-book" not found on Windows 10

I'm trying to build an HTML-page of my Jupyter notebook. I tried to run jupyter-book build mybookname but the command can't be found.
I tried to also install jupyter-book using the command pip install jupyter-book and added jupyter-book file path to environment variables, but I still can't build my book.
What should I do?
MY jupyter notebook didn't work after installing and calling in CMD.
then i only use "pip install simplejson" in command prompt (cmd) . Then i write "jupyter notebook" and it work!
someone uses "pip uninstall simplejson" before "pip install simplejson".
Maybe python needs to reinstall something (pip install/unistall).

Python packages required to run RStudio Quarto files in VS Code

I have been trying to run RStudio Quarto script in a fresh Ubuntu 20.04 installation but got into some trouble. Some Python packages that are required to run the simple hello.qmd were not there. I was getting these errors:
MoudleNotFoundError: No module named 'nbclient'
and a second error:
ModuleNotFoundError: No module named 'matplotlib_inline'
The first error was due to I had install the nbclient package. My default Python installation is python2.7. Quarto will not run well with Python 2.7; we should try with 3.7+. If your Linux doesn't come with it by default, this can easily be addressed by installing another Python version and configuring multiple Python versions with the help of the command:
sudo update-alternatives --config python
If no Python version shows up, then it means you have first to configure all your installed Python versions. This is very well explained at https://www.rosehosting.com/blog/how-to-install-and-switch-python-versions-on-ubuntu-20-04/
Once you have configured all your Python versions, every time that you run
sudo update-alternatives --config python, you will be prompted to enter the Python version you want as default. If you have a fresh Ubuntu 20.04, most likely that you have two: Python 2.7 and Python 3.8. Select 3.8 and you will fine. Quarto won't work with Python 2.7.
After you have python3 running and switched into, install nbclient with:
pip install nbclient.
The first error will now pass, but most likely you will get now
ModuleNotFoundError: No module named 'matplotlib_inline'. This is because you also need to install the package matplotlib-inline. This is not documented in the installation instructions of Quarto. But easy to fix. Run:
pip install matplotlib-inline
Now, go back to your VS Code, open the command palette and run Quarto: Render, or just type from the terminal:
quarto preview hello.qmd --no-browser --no-watch-inputs
You are done!

Install and run jupyterlab from src code as default

I have made a few changes to the jupyterlab code and I want to install and run this version as the default version on my machine.
According to the instructions I did the following:
pip install -e .
jlpm install
jlpm run build
jplm run build:core
jupyter lab build
The build is showing:
[LabBuildApp] Building in /opt/conda/share/jupyter/lab
When I run jupyter lab, I can see that the application is running from there:
[LabApp] JupyterLab application directory is /opt/conda/share/jupyter/lab
But this build is not from my src code. Only when I run with the --dev-mode tag I can see the changes I made in the code (the change was specifically in the packages).
How do I build jupyterlab from the src (including the packages) and have this be the version always to run on my machine? I feel that I am missing a step in the process.

Where are caffe libraries for sudo apt-get install caffe-cpu? Ubuntu 18.*

I have successfully installed the Caffe on Ubuntu 18.* using
`sudo apt-get install caffe-cpu`
The which caffe returns /usr/bin/caffe
I am successfully able to run caffe command on terminal, but problem is running the test files, as they are link to build directories of caffe and the problem is if I manually get the github repository of caffe and make build, it keeps failing and some of the dependencies candidates dont't have an installation candidate on Ubuntu 18.
Also all the examples on net available are for the previous type of manually built caffe
Normally, it will use with the default python in /usr/bin/python3. You can check
/usr/bin/python3
>>> import caffe
With the python in /usr/bin/python3, it does not require to add any addtional PYTHONPATH

App Deployment: Django not installing on server- AttributeError: 'module' object has no attribute 'lru_cache'

I am trying to deploy a Django App and for some reason, I keep getting this error. It seems to me that Django is not installed but it also errors when installing. Thank you for the help on this. I am deploying on Amazon EC2
(venv) ubuntu#ip----:~/quotes$ pip install Django
Collecting Django
Using cached Django-2.0.tar.gz
Complete output from command python setup.py egg_info:
Traceback (most recent call last):
File "", line 1, in
File "/tmp/pip-build-ceP6se/Django/setup.py", line 32, in
version = __import__('django').get_version()
File "django/__init__.py", line 1, in
from django.utils.version import get_version
File "django/utils/version.py", line 61, in
#functools.lru_cache()
AttributeError: 'module' object has no attribute 'lru_cache'
----------------------------------------
Command "python setup.py egg_info" failed with error code 1 in /tmp/pip-build-ceP6se/Django/
Django has stopped its support for Python 2 version, still you can try installing 1.11 version by using the below code.
pip install Django==1.11
According to the django 2.0 release notes, The Django 1.11.x series is the last to support Python 2.7 (Check it here)
So you can choose to use an older version of Django and then install it with this command:
pip install 'Django<2'
but if you decided to buildup your project using Django>=2.0 then you should create a virtual environment with python 3.4 or higher this way:
sudo apt-get update
sudo apt-get install python3 python3-pip
sudo -H pip3 install virtualenv
mkdir ~/myproject
cd ~/myproject
virtualenv -p `which python3` myprojectenv
source ~/myproject/myprojectenv/bin/activate
python -V
it should output something like this:
Python 3.X.Y
Now you are able to install the latest version of Django without any error:
pip install Django
Good luck,

Resources