could you help me with followings.
paramiko 16.1.0 library is in [python default] /usr/local/lib/python2.7/site-packages
But I can not upgrade paramiko 16.1.0 library to current paramiko 2.8.0 library; so I had to download paramiko 2.8.0 library into my path /home/pylib
Please let me know how I can force python to use /home/pylib/paramiko [paramiko 2.8.0 library] in my python code
Note: for now I am stuck with Python 2.7;I can not update PYTHONPATH
It's good practice to use virtual environments to avoid conflicts like this.
What is a virtual environment?
A virtual environment is basically like creating a fresh installation of Python for only one project. This allows you to easily have two different versions of a library installed for different projects.
How do I use virtual environments?
Install the virtualenv package: pip2 install virtualenv
Go to the root of your project cd path/to/project/root
Create a virtualenv: virtualenv -p /usr/bin/python2 venv
Activate the environment: . venv/bin/activate
Install the package version you want: pip2 install paramiko==2.8.0
Run your program: python something.py
To exit the virtual environment use: deactivate
Next time you want to run your program make sure you activate the environment with . venv/bin/activate first. None of the other steps need to be repeated.
force python to use my downloaded (to path : /home/pytlib) Paramiko library