Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Software based on Python 3.9 is not working on Windows 7

I made a standalone software using python3.9 which properly works on my system and another windows 10 system also, but I tried running that software on Windows 7 Ultimate and it shows some errors. Please note that I made the software by binding all the required python modules using PyInstaller. Those errors are as follows:

  1. Error loading Python DLL 'C:\Users\hp\AppData\Local\Temp_MEI19602\python39.dll'. LoadLibrary: The specified module could not be found.
  2. The program can't start because api-ms-win-core-path-l1-1-0.dll is missing from your computer. Try reinstalling the program to fix this problem.

What can I do to run this program on Windows 7?

like image 308
Tushar Agarwal Avatar asked Mar 20 '21 04:03

Tushar Agarwal


People also ask

Does Python 3.9 support Windows 7?

Note that Python 3.9.0 cannot be used on Windows 7 or earlier. Note that Python 3.8.6 cannot be used on Windows XP or earlier. Note that Python 3.8.6rc1 cannot be used on Windows XP or earlier.

Which version of Python can I use with Windows 7?

1 Answer. According to the official Python documentation reports, Python 3.9.

How do I run a Python program in idle 3.9 7?

To execute a file in IDLE, simply press the F5 key on your keyboard. You can also select Run → Run Module from the menu bar. Either option will restart the Python interpreter and then run the code that you've written with a fresh interpreter.


2 Answers

If you check out the Python documentation, you will see that Python 3.9 is not supported on Windows 7:

As specified in PEP 11, a Python release only supports a Windows platform while Microsoft considers the platform under extended support. This means that Python 3.9 supports Windows 8.1 and newer. If you require Windows 7 support, please install Python 3.8.

You can read more here.

like image 109
Jacob Lee Avatar answered Oct 07 '22 12:10

Jacob Lee


Times has come and may be you should learn how to build from the source:

Discussion: https://www.reddit.com/r/Python/comments/rbhd2n/python_39_310_on_windows_7/

  • Fork of CPython: https://github.com/NulAsh/cpython

    Installers: https://github.com/NulAsh/cpython/releases

  • Another workaround which creates the missing api-ms-win-core-path-l1-1-0.dll: https://github.com/nalexandru/api-ms-win-core-path-HACK

Both solutions use code from the Wine project to emulate missing functions (PathCchCanonicalizeEx, PathCchCombineEx, PathCchSkipRoot) on Windows 7.

PS:

Errors around api-ms-win-core-path-l1-1-0.dll and a such basically requires to install a particular vcredist_x86.exe/vcredist_x64.exe. But specifically that error in the Python 3.9 is because the DLL is a part of windows 8.

like image 24
Andry Avatar answered Oct 07 '22 11:10

Andry