我将尽量描述性但尽可能简短......
过去我一直在 Win10 上成功使用 GitBash。我在一段时间不使用它之后又回到了我的 Windows 机器上,似乎无法让它启动以前没有问题运行的 python 脚本。我为 Python3 创建了一个别名,名为 py。例如...
$ py --version
Python 3.7.1
Run Code Online (Sandbox Code Playgroud)
我可以很好地进入迭代器
$ py -i
Python 3.7.1 (v3.7.1:260ec2c36a, Oct 20 2018, 14:57:15) [MSC v.1915 64 bit
(AMD64)] on win32
Type "help", "copyright", "credits" or "license" for more information.
>>>
Run Code Online (Sandbox Code Playgroud)
我可以在迭代器中很好地运行我的脚本。但是,使用 ctrl+z 退出会引发错误。结合此错误,当我尝试从命令行运行 scipts 时,它挂起并且没有响应。见下文...
$ py -i
Python 3.7.1 (v3.7.1:260ec2c36a, Oct 20 2018, 14:57:15) [MSC v.1915 64 bit
(AMD64)] on win32
Type "help", "copyright", "credits" or "license" for more information.
>>> 0 [sig] bash …Run Code Online (Sandbox Code Playgroud)