I am not sure what’s the problem exactly since I remember distinctively being able to add a library to my script, but I can’t anymore,
I was trying to use the request(s) library, which seems to be, an internal library if I am not wrong? See:
I tried to make this little script work:
# Serializing a GET Request with .json() import requests resp = requests.get('https://reqres.in/api/users') resp_dict = resp.json() print(type(resp_dict)) # Returns: <class 'dict'>
(Described here: response.json() - Working with JSON in Python requests • datagy)
Except i get an error for this very first import:
If I remember correctly I had in the past successfully installed a new library using pip, by moving to the pip directory, here:
I remember I had to use this because this is a “LOCAL” version of capella, I don’t want to mix my “pip install” with other variable environement for other version of python ( How to Set Environment Variables in Windows 10 (alphr.com))
I think I had to do it every time and it was not saved? Anyway I had stoped my experiments that time and moved to other tasks.
Except today, I can’t even install a new library, in fact “PIP” itself does not work, here is an interesting message error that the CMD window displays:
Interesting right? (this is not the latest version of P4C by the way),
CHECK the name “YVANLUSSAUD” inside the ERROR MESSAGE.
What worked for me in the past was calling a library like this:
So I went ahead and tried the same method with “Requests”,
from requests import *
ModuleNotFoundError: No module named 'requests'
I did not get that error for “tkinter” or “copy”…
What could be wrong?