Virtual Python environments help in this situation too:
python -m venv amzpy
from within your home directory will create the amzpy (or whatever you decide to name it) directory. Activate the virtual environment using:
source amzpy/bin/activate
Install the extra requirements in your new virtual environment using pip as you used to do.
pip install requests selenium PyVirtualDisplay (no sudo/su necessary)
Then run the script to login and get your books.
When done using the virtual environment, enter "deactivate" at the command prompt. Delete the amzpy folder if you no longer need it.
|