Python Error
Hi, I had uninstalled and installed Python in Windows 10 but I am getting the error below. Can you please help ? C:\Users\mchak>pythonFatal Python error: init_sys_streams: can't initialize sys standard streamsPython runtime state: core initializedAttributeError: module 'io' has no attribute 'OpenWrapper' Current thread 0x9d44 (most recent call first): Regards,Mayukh -- https://mail.python.org/mailman/listinfo/python-list
Re: Python Error
> On 23 Nov 2020, at 14:10, Mayukh Chakraborty via Python-list > wrote: > > Hi, > I had uninstalled and installed Python in Windows 10 but I am getting the > error below. Can you please help ? > C:\Users\mchak>pythonFatal Python error: init_sys_streams: can't initialize > sys standard streamsPython runtime state: core initializedAttributeError: > module 'io' has no attribute 'OpenWrapper' > Current thread 0x9d44 (most recent call first): > Regards,Mayukh Which version of python are you installing and where did you download it from? Do you have more than one version of python installed? Does the command: py work? If you have python from python.org installed you should be able to list all the version you have installed with the command: py -0 That is zero not oh. Barry > -- > https://mail.python.org/mailman/listinfo/python-list > -- https://mail.python.org/mailman/listinfo/python-list
Re: Python Error
On 11/23/2020 9:10 AM, Mayukh Chakraborty via Python-list wrote: Hi, I had uninstalled and installed Python in Windows 10 but I am getting the error below. Can you please help ? C:\Users\mchak>python Fatal Python error: init_sys_streams: can't initialize sys standard streams Python runtime state: core initialized AttributeError: module 'io' has no attribute 'OpenWrapper' Current thread 0x9d44 (most recent call first): It is true that io has no OpenWrapper class. The question is What is trying to use that? What installer are you using? I would (re)download the one from python.org. -- Terry Jan Reedy -- https://mail.python.org/mailman/listinfo/python-list
Re: Python Error
1. The command 'py' doesn't work. It gives me the error below : C:\Users\mchak>pyFatal Python error: init_sys_streams: can't initialize sys standard streamsPython runtime state: core initializedAttributeError: module 'io' has no attribute 'open' Current thread 0x8290 (most recent call first): 2. If I use py -0, I get two installed versions. However, if I try to uninstall from Control Panel, I see only 3.9 version C:\Users\mchak>py -0Installed Pythons found by py Launcher for Windows -3.9-64 * -3.8-64 3. I tried to uninstall v3.9 and reinstall but it didn't solve the issue. Regards,Mayukh On Monday, November 23, 2020, 06:17:00 PM GMT, Barry Scott wrote: > On 23 Nov 2020, at 14:10, Mayukh Chakraborty via Python-list > wrote: > > Hi, > I had uninstalled and installed Python in Windows 10 but I am getting the > error below. Can you please help ? > C:\Users\mchak>pythonFatal Python error: init_sys_streams: can't initialize > sys standard streamsPython runtime state: core initializedAttributeError: > module 'io' has no attribute 'OpenWrapper' > Current thread 0x9d44 (most recent call first): > Regards,Mayukh Which version of python are you installing and where did you download it from? Do you have more than one version of python installed? Does the command: py work? If you have python from python.org installed you should be able to list all the version you have installed with the command: py -0 That is zero not oh. Barry > -- > https://mail.python.org/mailman/listinfo/python-list > -- https://mail.python.org/mailman/listinfo/python-list
Re: Python Error
Hi Terry, 1. The command py doesn't work. It gives me the error below : C:\Users\mchak>pyFatal Python error: init_sys_streams: can't initialize sys standard streamsPython runtime state: core initializedAttributeError: module 'io' has no attribute 'open' Current thread 0x8290 (most recent call first): 2. If I use py -0, I get two installed versions. However, if I try to uninstall from Control Panel, I see only 3.9 version C:\Users\mchak>py -0Installed Pythons found by py Launcher for Windows -3.9-64 * -3.8-64 3. I tried to uninstall v3.9 and reinstall but it didn't solve the issue. Regards,MayukhOn Monday, November 23, 2020, 06:34:43 PM GMT, Terry Reedy wrote: On 11/23/2020 9:10 AM, Mayukh Chakraborty via Python-list wrote: > Hi, > I had uninstalled and installed Python in Windows 10 but I am getting the > error below. Can you please help ? > C:\Users\mchak>python Fatal Python error: init_sys_streams: can't initialize sys standard streams Python runtime state: core initialized AttributeError: module 'io' has no attribute 'OpenWrapper' Current thread 0x9d44 (most recent call first): It is true that io has no OpenWrapper class. The question is What is trying to use that? What installer are you using? I would (re)download the one from python.org. -- Terry Jan Reedy -- https://mail.python.org/mailman/listinfo/python-list -- https://mail.python.org/mailman/listinfo/python-list
Re: Python Error
Hi, I have solved the issue by updating the Environment variables, now I am able to launch 'py' from the command prompt. However, I can't launch 'python' from command prompt. I am also encountering an issue when I try to execute the 'python' command from command prompt. I had reinstalled the python packages (numpy, pandas, scipy etc) but I can't find a solution for this error. --- C:\Users\mchak\Documents\Python>py ES.pyTraceback (most recent call last): File "C:\Users\mchak\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.8_qbz5n2kfra8p0\LocalCache\local-packages\Python38\site-packages\numpy\core\__init__.py", line 22, in from . import multiarray File "C:\Users\mchak\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.8_qbz5n2kfra8p0\LocalCache\local-packages\Python38\site-packages\numpy\core\multiarray.py", line 12, in from . import overrides File "C:\Users\mchak\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.8_qbz5n2kfra8p0\LocalCache\local-packages\Python38\site-packages\numpy\core\overrides.py", line 7, in from numpy.core._multiarray_umath import (ModuleNotFoundError: No module named 'numpy.core._multiarray_umath' During handling of the above exception, another exception occurred: Traceback (most recent call last): File "C:\Users\mchak\Documents\Python\ES.py", line 1, in import scipy as sp File "C:\Users\mchak\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.8_qbz5n2kfra8p0\LocalCache\local-packages\Python38\site-packages\scipy\__init__.py", line 61, in from numpy import show_config as show_numpy_config File "C:\Users\mchak\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.8_qbz5n2kfra8p0\LocalCache\local-packages\Python38\site-packages\numpy\__init__.py", line 140, in from . import core File "C:\Users\mchak\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.8_qbz5n2kfra8p0\LocalCache\local-packages\Python38\site-packages\numpy\core\__init__.py", line 48, in raise ImportError(msg)ImportError: IMPORTANT: PLEASE READ THIS FOR ADVICE ON HOW TO SOLVE THIS ISSUE! Importing the numpy C-extensions failed. This error can happen formany reasons, often due to issues with your setup or how NumPy wasinstalled. We have compiled some common reasons and troubleshooting tips at: https://numpy.org/devdocs/user/troubleshooting-importerror.html Please note and check the following: * The Python version is: Python3.9 from "C:\Users\mchak\AppData\Local\Programs\Python\Python39\python.exe" * The NumPy version is: "1.19.4" and make sure that they are the versions you expect.Please carefully study the documentation linked above for further help. Original error was: No module named 'numpy.core._multiarray_umath' Regards,MayukhOn Monday, November 23, 2020, 08:17:06 PM GMT, Mayukh Chakraborty via Python-list wrote: Hi Terry, 1. The command py doesn't work. It gives me the error below : C:\Users\mchak>pyFatal Python error: init_sys_streams: can't initialize sys standard streamsPython runtime state: core initializedAttributeError: module 'io' has no attribute 'open' Current thread 0x8290 (most recent call first): 2. If I use py -0, I get two installed versions. However, if I try to uninstall from Control Panel, I see only 3.9 version C:\Users\mchak>py -0Installed Pythons found by py Launcher for Windows -3.9-64 * -3.8-64 3. I tried to uninstall v3.9 and reinstall but it didn't solve the issue. Regards,Mayukh On Monday, November 23, 2020, 06:34:43 PM GMT, Terry Reedy wrote: On 11/23/2020 9:10 AM, Mayukh Chakraborty via Python-list wrote: > Hi, > I had uninstalled and installed Python in Windows 10 but I am getting the > error below. Can you please help ? > C:\Users\mchak>python Fatal Python error: init_sys_streams: can't initialize sys standard streams Python runtime state: core initialized AttributeError: module 'io' has no attribute 'OpenWrapper' Current thread 0x9d44 (most recent call first): It is true that io has no OpenWrapper class. The question is What is trying to use that? What installer are you using? I would (re)download the one from python.org. -- Terry Jan Reedy -- https://mail.python.org/mailman/listinfo/python-list -- https://mail.python.org/mailman/listinfo/python-list -- https://mail.python.org/mailman/listinfo/python-list
Re: Python Error
Barry Scott wrote: If you have python from python.org installed you should be able to list all the version you have installed with the command: py -0 When was that '-0' feature added? I have Python 3.6 from Python.org and here a 'py.exe -0' gives: Requested Python version (0) not installed But using 'py.exe -0' from Python 3.9 correctly gives: -3.6-32 * -2.7-32 -- --gv -- https://mail.python.org/mailman/listinfo/python-list
