classification
Title: Scripts folder is Empty in python 3.8.2 for Windows 7.
Type: Stage:
Components: Installation, Windows Versions: Python 3.8
process
Status: open Resolution:
Dependencies: Superseder:
Assigned To: Nosy List: BenTen Jan, Why Me, kuzja, paul.moore, steve.dower, tim.golden, zach.ware
Priority: normal Keywords:

Created on 2020-04-26 14:18 by BenTen Jan, last changed 2020-07-29 21:31 by steve.dower.

Files
File name Uploaded Description Edit
Installation Log.zip BenTen Jan, 2020-04-26 14:18 Log File of %temp% folder
Messages (8)
msg367307 - (view) Author: BenTen Jan (BenTen Jan) Date: 2020-04-26 14:18
I downloaded python 3.8.2 which is the latest version of python for windows. Run as admin , changed path of installation though its getting  empty Scripts folder. though setup shows successful.

Please find attached log files from my %temp% folder.

Thanks Regards
Ben
msg367443 - (view) Author: Steve Dower (steve.dower) * (Python committer) Date: 2020-04-27 18:47
Thanks for including logs!

It looks like pip ran into an issue during install:

C:\Users\<User>\AppData\Local\Temp\tmpppkvx8p2\pip-19.2.3-py2.py3-none-any.whl\pip\_vendor\ipaddress.py:1106: SyntaxWarning: 'str' object is not callable; perhaps you missed a comma?
C:\Users\<User>\AppData\Local\Temp\tmpppkvx8p2\pip-19.2.3-py2.py3-none-any.whl\pip\_vendor\ipaddress.py:1106: SyntaxWarning: 'str' object is not callable; perhaps you missed a comma?
Traceback (most recent call last):
  File "C:\Python\Python38-32\lib\runpy.py", line 193, in _run_module_as_main
    return _run_code(code, main_globals, None,
  File "C:\Python\Python38-32\lib\runpy.py", line 86, in _run_code
    exec(code, run_globals)
  File "C:\Python\Python38-32\lib\ensurepip\__main__.py", line 5, in <module>
    sys.exit(ensurepip._main())
  File "C:\Python\Python38-32\lib\ensurepip\__init__.py", line 200, in _main
    return _bootstrap(
  File "C:\Python\Python38-32\lib\ensurepip\__init__.py", line 119, in _bootstrap
    return _run_pip(args + , additional_paths)
  File "C:\Python\Python38-32\lib\ensurepip\__init__.py", line 27, in _run_pip
    import pip._internal
  File "<frozen zipimport>", line 259, in load_module
  File "C:\Users\<User>\AppData\Local\Temp\tmpppkvx8p2\pip-19.2.3-py2.py3-none-any.whl\pip\_internal\__init__.py", line 40, in <module>
  File "<frozen zipimport>", line 259, in load_module
  File "C:\Users\<User>\AppData\Local\Temp\tmpppkvx8p2\pip-19.2.3-py2.py3-none-any.whl\pip\_internal\cli\autocompletion.py", line 8, in <module>
  File "<frozen zipimport>", line 259, in load_module
  File "C:\Users\<User>\AppData\Local\Temp\tmpppkvx8p2\pip-19.2.3-py2.py3-none-any.whl\pip\_internal\cli\main_parser.py", line 7, in <module>
  File "<frozen zipimport>", line 259, in load_module
  File "C:\Users\<User>\AppData\Local\Temp\tmpppkvx8p2\pip-19.2.3-py2.py3-none-any.whl\pip\_internal\cli\cmdoptions.py", line 24, in <module>
  File "<frozen zipimport>", line 259, in load_module
  File "C:\Users\<User>\AppData\Local\Temp\tmpppkvx8p2\pip-19.2.3-py2.py3-none-any.whl\pip\_internal\models\search_scope.py", line 11, in <module>
  File "<frozen zipimport>", line 259, in load_module
  File "C:\Users\<User>\AppData\Local\Temp\tmpppkvx8p2\pip-19.2.3-py2.py3-none-any.whl\pip\_internal\utils\misc.py", line 21, in <module>
  File "<frozen zipimport>", line 259, in load_module
  File "C:\Users\<User>\AppData\Local\Temp\tmpppkvx8p2\pip-19.2.3-py2.py3-none-any.whl\pip\_vendor\pkg_resources\__init__.py", line 35, in <module>
  File "C:\Python\Python38-32\lib\plistlib.py", line 65, in <module>
    from xml.parsers.expat import ParserCreate
  File "C:\Python\Python38-32\lib\xml\parsers\expat.py", line 4, in <module>
    from pyexpat import *
ImportError: DLL load failed while importing pyexpat: The specified module could not be found.
Error 0x80070001: Command line returned an error.
Error 0x80070001: QuietExec Failed

However, as far as I can tell, all the dependencies it needs were installed. So the most likely cause is a virus scanner interfering. (Unless Python does not work for you at all, though that is still likely to be a scanner, since the setup logs seem fine.)

The easiest fix will be to disable your virus scanner and run a Repair install. That should make sure that everything is installed. If pip is the only thing missing, you could also run "python -m ensurepip" as admin.
msg367444 - (view) Author: Steve Dower (steve.dower) * (Python committer) Date: 2020-04-27 18:49
As a secondary issue, why didn't the installer fail on the pip failure? Did we decide at some point not to fail the whole thing just because of pip? (It's probably the most unreliable part, as it's a custom action rather than simple installation.)
msg367499 - (view) Author: BenTen Jan (BenTen Jan) Date: 2020-04-28 05:40
First and foremost thanks for replying,

1. I don't have any virus scanner installed.
2. I have tried running "python -m ensurepip" it shows me Following error 

C:\Python>Python get-pip.py
Traceback (most recent call last):
  File "get-pip.py", line 22711, in <module>
    main()
  File "get-pip.py", line 198, in main
    bootstrap(tmpdir=tmpdir)
  File "get-pip.py", line 82, in bootstrap
    from pip._internal.cli.main import main as pip_entry_point
  File "<frozen zipimport>", line 259, in load_module
  File "C:\Users\KNN\AppData\Local\Temp\tmpvrhu1rqz\pip.zip\pip\_internal\cli\main.py", line 10, in <module>
  File "<frozen zipimport>", line 259, in load_module
  File "C:\Users\KNN\AppData\Local\Temp\tmpvrhu1rqz\pip.zip\pip\_internal\cli\autocompletion.py", line 9, in <module>
  File "<frozen zipimport>", line 259, in load_module
  File "C:\Users\KNN\AppData\Local\Temp\tmpvrhu1rqz\pip.zip\pip\_internal\cli\main_parser.py", line 7, in <module>
  File "<frozen zipimport>", line 259, in load_module
  File "C:\Users\KNN\AppData\Local\Temp\tmpvrhu1rqz\pip.zip\pip\_internal\cli\cmdoptions.py", line 28, in <module>
  File "<frozen zipimport>", line 259, in load_module
  File "C:\Users\KNN\AppData\Local\Temp\tmpvrhu1rqz\pip.zip\pip\_internal\models\target_python.py", line 4, in <module>
  File "<frozen zipimport>", line 259, in load_module
  File "C:\Users\KNN\AppData\Local\Temp\tmpvrhu1rqz\pip.zip\pip\_internal\utils\misc.py", line 20, in <module>
  File "<frozen zipimport>", line 259, in load_module
  File "C:\Users\KNN\AppData\Local\Temp\tmpvrhu1rqz\pip.zip\pip\_vendor\pkg_resources\__init__.py", line 35, in <module>
  File "C:\Python\Python38-32\lib\plistlib.py", line 65, in <module>
    from xml.parsers.expat import ParserCreate
  File "C:\Python\Python38-32\lib\xml\parsers\expat.py", line 4, in <module>
    from pyexpat import *
ImportError: DLL load failed while importing pyexpat: The specified module could not be found.

3. Whole Scripts folder in python root is empty, i don't know if its ok with 3.8.2 but Scripts folder was having files in 2.X versions...

Thanks & Appreciate The Handwork of yours towards PY.COMM..

Ben
msg367548 - (view) Author: Steve Dower (steve.dower) * (Python committer) Date: 2020-04-28 17:38
Yes, the only thing that should be in your Scripts folder after install is pip. Python itself never puts anything there - it's for other things that you may install.

Could you try running these environment commands and then try installing pip again?

set PYTHONHOME=
set PYTHONPATH=
set PATH=C:\Windows\System32;C:\Windows
python get-pip.py
msg367645 - (view) Author: (kuzja) Date: 2020-04-29 13:56
Here the same problem occurred when installing Python in Win7 Pro. Both standard and custom (with pip checked) installations lead to the same result (i.e. the empty Scripts folder).
It seems that the problem originates somewhere between Python 3.6 and 3.7, as 3.7 suffers from the same problem too, while 3.6 installed correctly.
msg374579 - (view) Author: Why Me (Why Me) Date: 2020-07-29 17:53
I had the same issue (win 10, py 3.8.5, executable installer). The solution i've found is to install python to non-standard catalog (D:/ instead of windows user folder which is under access protection). In this case, the file "easy_install.exe" will be created in the Scripts folder. Then open console inside the folder and call "easy_install pip", this will install pip. After that just copy everything to the standard catalog and don't forget to change the environment variables. Hope this helps.
msg374588 - (view) Author: Steve Dower (steve.dower) * (Python committer) Date: 2020-07-29 21:31
It might help, but it will leave your install broken in a number of other ways.

For other people finding this issue, please share your install logs (look in %TEMP% for the most recently created set of "python*.log" files). Also share your PATH, PYTHONPATH and PYTHONHOME environment variables (if they are set), and any other versions of Python you have installed.
History
Date User Action Args
2020-07-29 21:31:23steve.dowersetcomponents: + Installation
2020-07-29 21:31:15steve.dowersetmessages: + msg374588
2020-07-29 17:53:31Why Mesetnosy: + Why Me
messages: + msg374579
components: - Installation
2020-04-29 13:56:05kuzjasetnosy: + kuzja
messages: + msg367645
2020-04-28 17:38:00steve.dowersetmessages: + msg367548
2020-04-28 05:40:47BenTen Jansetmessages: + msg367499
2020-04-27 18:49:33steve.dowersetmessages: + msg367444
2020-04-27 18:47:34steve.dowersetmessages: + msg367443
2020-04-26 14:25:05xtreaksetnosy: + paul.moore, tim.golden, zach.ware, steve.dower
components: + Windows
2020-04-26 14:18:10BenTen Jancreate