0

At the start, when i installed python, pip was installed automatically but somehow i messed with the administrator access in windows and messed it very bad, By reading some online articles, I downloaded the get-pip.py and tried to run it with python in that same folder: python get-pip.py

But the error i get is :

Traceback (most recent call last):
  File "get-pip.py", line 23484, in <module>
    main()
  File "get-pip.py", line 187, in main
    tmpdir = tempfile.mkdtemp()
  File "C:\Users\Vamsi\AppData\Local\Programs\Python\Python38-32\lib\tempfile.py", line 348, in mkdtemp
    prefix, suffix, dir, output_type = _sanitize_params(prefix, suffix, dir)
  File "C:\Users\Vamsi\AppData\Local\Programs\Python\Python38-32\lib\tempfile.py", line 117, in _sanitize_params
    dir = gettempdir()
  File "C:\Users\Vamsi\AppData\Local\Programs\Python\Python38-32\lib\tempfile.py", line 286, in gettempdir
    tempdir = _get_default_tempdir()
  File "C:\Users\Vamsi\AppData\Local\Programs\Python\Python38-32\lib\tempfile.py", line 218, in _get_default_tempdir
    raise FileNotFoundError(_errno.ENOENT,
FileNotFoundError: [Errno 2] No usable temporary directory found in ['C:\\Users\\Vamsi\\AppData\\Local\\Temp', 'C:\\Users\\Vamsi\\AppData\\Local\\Temp', 'C:\\Users\\Vamsi\\AppData\\Local\\Temp', 'C:\\WINDOWS\\Temp', 'c:\\temp', 'c:\\tmp', '\\temp', '\\tmp', 'C:\\Users\\Vamsi']

1 Answers1

0

In order to run get-pip.py you need make sure that you are in the directory where it is installed in. For instance i see that the dirctory you are in is C:\Users\Vamsi make sure that it is saved to this directory or cd to the right one.

BeeFriedman
  • 1,800
  • 1
  • 11
  • 29
  • The same error is repeating even after i changed the directory to the same directory get-pip.py file is in. – vamsi vakalapudi Oct 13 '20 at 13:06
  • This post might be helpful https://stackoverflow.com/questions/16996125/no-usable-temporary-directory-found In short it says that the only other reason you get this error is or because you don't have the required permissions for the file or becuase there is not enough space on the disk. – BeeFriedman Oct 13 '20 at 15:21