3

Python will not run in git bash (Windows). When I type python in the command line, it takes me to a blank line without saying that it has entered python 3.9.1 like it does in Powershell. It doesn't give me an error message, but python just doesn't run.

This is what happens when I type python. It just freezes. Any Idea on how to fix it. I cannot use command prompt because it causes some error when I import a module it says ModuleNotFound.

Selvi@DESKTOP-H75HFL5 MINGW64 /
$ python

2*2
2

2 Answers 2

8

Getting python run in git bash you simply can type winpty python or you can use python -i

Note: if you use winpty python you can exit python with CTRL + Z or exit(), but if you used python -i, you only can exit with exit().

Sign up to request clarification or add additional context in comments.

Comments

0

Actually I was having the same problem. The only thing is that when you enter the Python command prompt with python -i, you can only exit it with quit()

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.