Jul-03-2021, 04:21 PM
Jul-03-2021, 04:24 PM
(Jul-03-2021, 04:21 PM)ogg130 Wrote: [ -> ]Windows 10.
I run python3 from git bash or command prompt. Hey look, it's great and everything works!
I run a simple hello world script by running 'python scriptname.py', it seems to run, but doesnt return any output.
Nothing works. Why is this so difficult and what can I do to get through this?
- I've disabled the horseshit windows store bs.
- I tried responsed from multiple stackoverflow threads telling me to change registry keys that dont exist.
- I have validated and checked that the python exceutable is in my path and that the executable exists where specified in the path.
- I have uninstalled and reinstalled python with reboots in between mulitple times.
- I have added PYTHONPATH and PYTHONHOME at peoples suggestion, and removed them because people said they never should be used in Windows and just caused errors anyways.
- I have removed and changed the shebang in the script per stackoverflow selections.
- I have looked for installation documentation on Python.org and cant find anything that helps.
Thank you in advance for helping me understand why this simple task is proving to be not simple.
Jul-03-2021, 09:50 PM
Look at Python 3.9/3.8 and pip installation under Windows
![[Image: WfreEG.png]](https://imagizer.imageshack.com/v2/640x480q90/924/WfreEG.png)
I had changed to
So then main version that use most should always be set like this,
i have a lot version Anaconda/Miniconda/PyPY...ect ,all version
(Jul-03-2021, 04:24 PM)ogg130 Wrote: [ -> ]I run a simple hello world script by running 'python scriptname.py', it seems to run, but doesnt return any output.You test as in link
python -V
and and pip -V
C:\Users\Tom>python -V Python 3.9.5 C:\Users\Tom>python -c "import sys; print(sys.executable)" C:\python39\python.exe C:\Users\Tom>pip -V pip 21.1.3 from c:\python39\lib\site-packages\pip (python 3.9) C:\Users\Tom>Why this work has only to do with that Environment Variables Path is set to Python 3.9.
![[Image: WfreEG.png]](https://imagizer.imageshack.com/v2/640x480q90/924/WfreEG.png)
I had changed to
C:\python37
and C:\python37\Scripts
then it would use Python 3.7 when to python -V
So then main version that use most should always be set like this,
i have a lot version Anaconda/Miniconda/PyPY...ect ,all version
python.org
can be access bye using py
(Python install put a py.exe
in the Windows folder).C:\Users\Tom>py -2.7 -V Python 2.7.9 C:\Users\Tom>py -3.4 -V Python 3.4.2 C:\Users\Tom>py -3.6 -V Python 3.6.4 C:\Users\Tom>py -3.7 -m pip install requests Requirement already satisfied: requests in c:\python37\lib\site-packages (2.22.0
Jul-06-2021, 11:14 AM
Download the Python Installer binaries. Open the official Python website in your web browser. Navigate to the Downloads tab for Windows. Choose the latest Python 3 release.
Run the Executable Installer. Once the installer is downloaded, run the Python installer. Check the Install launcher for all users check box.
Add Python to environmental variables. The last (optional) step in the installation process is to add Python Path to the System Environment variables.
Verify the Python Installation. You have now successfully installed Python 3.7.3 on Windows 10.
Run the Executable Installer. Once the installer is downloaded, run the Python installer. Check the Install launcher for all users check box.
Add Python to environmental variables. The last (optional) step in the installation process is to add Python Path to the System Environment variables.
Verify the Python Installation. You have now successfully installed Python 3.7.3 on Windows 10.