Enthought Canopy GUI won't open - enthought
I've downloaded Enthought Canopy Express onto my 64-bit Windows 10 laptop, but when I try to open the Canopy program it won't open.
If I try to open it from the desktop shortcut or go into the program files and try to open it directly from the .exe file, all it will do is show the splash page, which then disappears after showing for a few seconds, and then nothing happens. Also after the splash page is gone, task manager shows that Canopy isn't running.
The PyLab application will open and works fine, but I need the actual Enthought Canopy application to work for a class I'm taking.
When I installed it for the very first time, it did open and I was able to use the Enthought Canopy application, but ever since I closed out of it since then it hasn't worked.
When I go into the program files to try and open it from the .exe file, for the file Canopy.exe it will open the splash page and then close, and for Canopy_cli.exe it will open a command prompt looking window, then the splash page, and then both close. The file _python.exe will open and work, and the file _pythonw.exe does nothing.
(These files are at C:\Users\charizard\AppData\Local\Enthought\Canopy\App if that makes any difference.)
I've uninstalled and restarted and reinstalled several times, and I've tried the "Full Reset" suggested in this article. My user name is just "charizard" and my computer name is "messier42", so the problem isn't that it's a non-ASCII user name.
I have also tried the test to see if it's a problem with the PYTHONPATH or PYTHONHOME environment variables like it suggests in this article, but it didn't start Canopy.
This is what I got from the command prompt when I tested that:
Microsoft Windows [Version 10.0.10240]
(c) 2015 Microsoft Corporation. All rights reserved.
C:\Users\charizard>
C:\Users\charizard>set pythonpath=
C:\Users\charizard>set pythonhome=
C:\Users\charizard>set
ALLUSERSPROFILE=C:\ProgramData
APPDATA=C:\Users\charizard\AppData\Roaming
asl.log=Destination=file
CommonProgramFiles=C:\Program Files\Common Files
CommonProgramFiles(x86)=C:\Program Files (x86)\Common Files
CommonProgramW6432=C:\Program Files\Common Files
COMPUTERNAME=MESSIER42
ComSpec=C:\WINDOWS\system32\cmd.exe
FPS_BROWSER_APP_PROFILE_STRING=Internet Explorer
FPS_BROWSER_USER_PROFILE_STRING=Default
FP_NO_HOST_CHECK=NO
HOMEDRIVE=C:
HOMEPATH=\Users\charizard
LOCALAPPDATA=C:\Users\charizard\AppData\Local
LOGONSERVER=\\MicrosoftAccount
NUMBER_OF_PROCESSORS=4
OS=Windows_NT
Path=C:\ProgramData\Oracle\Java\javapath;C:\Program Files (x86)\NVIDIA Corporation\PhysX\Common;C:\Program Files\Broadcom\Broadcom 802.11 Network Adapter;;C:\Program Files (x86)\Intel\iCLS Client\;C:\Program Files\Intel\iCLS Client\;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System32\WindowsPowerShell\v1.0\;C:\Program Files\Intel\Intel(R) Management Engine Components\DAL;C:\Program Files\Intel\Intel(R) Management Engine Components\IPT;C:\Program Files (x86)\Intel\Intel(R) Management Engine Components\DAL;C:\Program Files (x86)\Intel\Intel(R) Management Engine Components\IPT;C:\Program Files\WIDCOMM\Bluetooth Software\;C:\Program Files\WIDCOMM\Bluetooth Software\syswow64;C:\Program Files\Acer\Remote Files\;C:\Program Files (x86)\Calibre2\;C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;C:\WINDOWS\System32\WindowsPowerShell\v1.0\;C:\Program Files (x86)\Skype\Phone\;c:\users\charizard\appdata\local\enthought\canopy\user\scripts;C:\Users\charizard\AppData\Roaming\Dashlane\3.5.2.91395\bin\Firefox_Extension\{442718d9-475e-452a-b3e1-fb1ee16b8e9f}\components;C:\Users\charizard\AppData\Local\Enthought\Canopy\User;C:\Users\charizard\AppData\Local\Enthought\Canopy\User\Scripts
PATHEXT=.COM;.EXE;.BAT;.CMD;.VBS;.VBE;.JS;.JSE;.WSF;.WSH;.MSC
PROCESSOR_ARCHITECTURE=AMD64
PROCESSOR_IDENTIFIER=Intel64 Family 6 Model 69 Stepping 1, GenuineIntel
PROCESSOR_LEVEL=6
PROCESSOR_REVISION=4501
ProgramData=C:\ProgramData
ProgramFiles=C:\Program Files
ProgramFiles(x86)=C:\Program Files (x86)
ProgramW6432=C:\Program Files
PROMPT=$P$G
PSModulePath=C:\WINDOWS\system32\WindowsPowerShell\v1.0\Modules\
PUBLIC=C:\Users\Public
SESSIONNAME=Console
SystemDrive=C:
SystemRoot=C:\WINDOWS
TEMP=C:\Users\CHARIZ~1\AppData\Local\Temp
TMP=C:\Users\CHARIZ~1\AppData\Local\Temp
USERDOMAIN=MESSIER42
USERDOMAIN_ROAMINGPROFILE=MESSIER42
USERNAME=charizard
USERPROFILE=C:\Users\charizard
windir=C:\WINDOWS
[.... later after correcting typo...]
C:\Users\charizard>cd "%localappdata%\enthought\canopy\app"
C:\Users\charizard\AppData\Local\Enthought\Canopy\App>_python.exe canopy-script.pyw
Traceback (most recent call last):
File "canopy-script.pyw", line 776, in <module>
File "canopy-script.pyw", line 336, in bootstrap
File "canopy-script.pyw", line 363, in chainload
File "canopy-script.pyw", line 762, in _chainload
File "C:\Users\charizard\AppData\Local\Enthought\Canopy\App\appdata\canopy-1.5.5.3123.win-x86_64\Canopy-script.pyw", line 8, in <module>
sys.exit(main())
File "build\bdist.win-amd64\egg\canopy\app\bootstrap.py", line 2421, in main
File "build\bdist.win-amd64\egg\canopy\app\bootstrap.py", line 2357, in send_bug_report
File "build\bdist.win-amd64\egg\canopy\feedback\data_reporter.py", line 25, in <module>
File "build\bdist.win-amd64\egg\canopy\app\application.py", line 22, in <module>
File "C:\Users\charizard\AppData\Local\Enthought\Canopy\App\appdata\canopy-1.5.5.3123.win-x86_64\Lib\site-packages\envisage\ui\tasks\api.py", line 2, in <module>
from preferences_pane import PreferencesPane
File "C:\Users\charizard\AppData\Local\Enthought\Canopy\App\appdata\canopy-1.5.5.3123.win-x86_64\Lib\site-packages\envisage\ui\tasks\preferences_pane.py", line 4, in <module>
from traitsui.api import Controller
File "C:\Users\charizard\AppData\Local\Enthought\Canopy\App\appdata\canopy-1.5.5.3123.win-x86_64\Lib\site-packages\traitsui\api.py", line 41, in <module>
from .editors.api import (BooleanEditor, ButtonEditor,
File "C:\Users\charizard\AppData\Local\Enthought\Canopy\App\appdata\canopy-1.5.5.3123.win-x86_64\Lib\site-packages\traitsui\editors\__init__.py", line 27, in <module>
from .api import (toolkit, BooleanEditor, ButtonEditor,
File "C:\Users\charizard\AppData\Local\Enthought\Canopy\App\appdata\canopy-1.5.5.3123.win-x86_64\Lib\site-packages\traitsui\editors\api.py", line 8, in <module>
from .array_editor import ArrayEditor
File "C:\Users\charizard\AppData\Local\Enthought\Canopy\App\appdata\canopy-1.5.5.3123.win-x86_64\Lib\site-packages\traitsui\editors\array_editor.py", line 27, in <module>
import numpy
File "C:\Users\charizard\AppData\Local\Enthought\Canopy\App\appdata\canopy-1.5.5.3123.win-x86_64\Lib\site-packages\numpy\__init__.py", line 185, in <module>
from . import add_newdocs
File "C:\Users\charizard\AppData\Local\Enthought\Canopy\App\appdata\canopy-1.5.5.3123.win-x86_64\Lib\site-packages\numpy\add_newdocs.py", line 13, in <module>
from numpy.lib import add_newdoc
File "C:\Users\charizard\AppData\Local\Enthought\Canopy\App\appdata\canopy-1.5.5.3123.win-x86_64\Lib\site-packages\numpy\lib\__init__.py", line 17, in <module>
from . import scimath as emath
ImportError: cannot import name scimath
C:\Users\charizard\AppData\Local\Enthought\Canopy\App>
C:\Users\charizard\AppData\Local\Enthought\Canopy\App>Uncaught exception captured
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "build\bdist.win-amd64\egg\canopy\app\main.py", line 53, in main
File "build\bdist.win-amd64\egg\canopy\app\application_launcher.py", line 350, in launch
File "build\bdist.win-amd64\egg\canopy\app\application.py", line 361, in run
File "C:\Users\charizard\AppData\Local\Enthought\Canopy\App\appdata\canopy-1.5.5.3123.win-x86_64\lib\site-packages\envisage\ui\tasks\tasks_application.py", line 131, in run
started = self.start()
File "build\bdist.win-amd64\egg\canopy\app\application.py", line 295, in start
File "C:\Users\charizard\AppData\Local\Enthought\Canopy\App\appdata\canopy-1.5.5.3123.win-x86_64\lib\site-packages\envisage\application.py", line 295, in start
self.plugin_manager.start()
File "build\bdist.win-amd64\egg\canopy\app\canopy_plugin_manager.py", line 140, in start
File "C:\Users\charizard\AppData\Local\Enthought\Canopy\App\appdata\canopy-1.5.5.3123.win-x86_64\lib\site-packages\envisage\composite_plugin_manager.py", line 133, in start
self.start_plugin(plugin)
File "C:\Users\charizard\AppData\Local\Enthought\Canopy\App\appdata\canopy-1.5.5.3123.win-x86_64\lib\site-packages\envisage\composite_plugin_manager.py", line 143, in start_plugin
plugin.activator.start_plugin(plugin)
File "C:\Users\charizard\AppData\Local\Enthought\Canopy\App\appdata\canopy-1.5.5.3123.win-x86_64\lib\site-packages\envisage\plugin_activator.py", line 30, in start_plugin
plugin.start()
File "build/bdist.macosx-10.6-x86_64/egg/canopy_data_import_addon/plugin.py", line 79, in start
File "C:\Users\charizard\AppData\Local\Enthought\Canopy\App\appdata\canopy-1.5.5.3123.win-x86_64\lib\site-packages\envisage\application.py", line 370, in get_service
protocol, query, minimize, maximize
File "C:\Users\charizard\AppData\Local\Enthought\Canopy\App\appdata\canopy-1.5.5.3123.win-x86_64\lib\site-packages\envisage\service_registry.py", line 77, in get_service
services = self.get_services(protocol, query, minimize, maximize)
File "C:\Users\charizard\AppData\Local\Enthought\Canopy\App\appdata\canopy-1.5.5.3123.win-x86_64\lib\site-packages\envisage\service_registry.py", line 114, in get_services
actual_protocol, name, obj, properties, service_id
File "C:\Users\charizard\AppData\Local\Enthought\Canopy\App\appdata\canopy-1.5.5.3123.win-x86_64\lib\site-packages\envisage\service_registry.py", line 258, in _resolve_factory
obj = obj(**properties)
File "build\bdist.win-amd64\egg\canopy\plugin\plugin.py", line 183, in _create_package_manager_service
File "C:\Users\charizard\AppData\Local\Enthought\Canopy\App\appdata\canopy-1.5.5.3123.win-x86_64\lib\site-packages\envisage\application.py", line 370, in get_service
protocol, query, minimize, maximize
File "C:\Users\charizard\AppData\Local\Enthought\Canopy\App\appdata\canopy-1.5.5.3123.win-x86_64\lib\site-packages\envisage\service_registry.py", line 77, in get_service
services = self.get_services(protocol, query, minimize, maximize)
File "C:\Users\charizard\AppData\Local\Enthought\Canopy\App\appdata\canopy-1.5.5.3123.win-x86_64\lib\site-packages\envisage\service_registry.py", line 114, in get_services
actual_protocol, name, obj, properties, service_id
File "C:\Users\charizard\AppData\Local\Enthought\Canopy\App\appdata\canopy-1.5.5.3123.win-x86_64\lib\site-packages\envisage\service_registry.py", line 258, in _resolve_factory
obj = obj(**properties)
File "build\bdist.win-amd64\egg\canopy\accounts\plugin.py", line 69, in _create_account_service
File "build\bdist.win-amd64\egg\canopy\accounts\account_service.py", line 359, in __init__
File "C:\Users\charizard\AppData\Local\Enthought\Canopy\App\appdata\canopy-1.5.5.3123.win-x86_64\lib\site-packages\traits\has_traits.py", line 3285, in _init_trait_listeners
getattr( self, '_init_trait_%s_listener' % data[0] )( name, *data )
File "C:\Users\charizard\AppData\Local\Enthought\Canopy\App\appdata\canopy-1.5.5.3123.win-x86_64\lib\site-packages\traits\has_traits.py", line 3340, in _init_trait_delegate_listener
self.on_trait_change( notify, name_pattern, target=self )
File "C:\Users\charizard\AppData\Local\Enthought\Canopy\App\appdata\canopy-1.5.5.3123.win-x86_64\lib\site-packages\traits\has_traits.py", line 2584, in on_trait_change
listener.register( self )
File "C:\Users\charizard\AppData\Local\Enthought\Canopy\App\appdata\canopy-1.5.5.3123.win-x86_64\lib\site-packages\traits\traits_listener.py", line 433, in register
value = getattr( self, type )( new, name, False )
File "C:\Users\charizard\AppData\Local\Enthought\Canopy\App\appdata\canopy-1.5.5.3123.win-x86_64\lib\site-packages\traits\traits_listener.py", line 701, in _register_simple
return next.register( getattr( object, name ) )
File "build\bdist.win-amd64\egg\canopy\accounts\account_service.py", line 308, in _preferences_default
File "build\bdist.win-amd64\egg\canopy\accounts\account_service.py", line 314, in _enstaller_config_default
File "C:\Users\charizard\AppData\Local\Enthought\Canopy\App\appdata\canopy-1.5.5.3123.win-x86_64\lib\site-packages\enstaller\config.py", line 299, in from_file
ret = _create(fp)
File "C:\Users\charizard\AppData\Local\Enthought\Canopy\App\appdata\canopy-1.5.5.3123.win-x86_64\lib\site-packages\enstaller\config.py", line 268, in _create
parsed = parse_assignments(fp)
File "C:\Users\charizard\AppData\Local\Enthought\Canopy\App\appdata\canopy-1.5.5.3123.win-x86_64\lib\site-packages\egginst\utils.py", line 207, in parse_assignments
return _AssignmentParser().parse(file_or_filename.read())
File "C:\Users\charizard\AppData\Local\Enthought\Canopy\App\appdata\canopy-1.5.5.3123.win-x86_64\lib\site-packages\egginst\utils.py", line 172, in parse
root = ast.parse(s)
File "C:\Users\charizard\AppData\Local\Enthought\Canopy\App\appdata\canopy-1.5.5.3123.win-x86_64\lib\ast.py", line 37, in parse
return compile(source, filename, mode, PyCF_ONLY_AST)
TypeError: compile() expected string without null bytes
Exception occurred in traits notification handler.
Please check the log file for details.
Exception occurred in traits notification handler for object: <canopy.logging.logging_service.LoggingService object at 0x00000000054EAA98>, trait: exception_added, old value: <undefined>, new value: <LogRecord: root, 40, build\bdist.win-amd64\egg\canopy\logging\logging_service.py, 154, "Uncaught exception captured">
Traceback (most recent call last):
File "C:\Users\charizard\AppData\Local\Enthought\Canopy\App\appdata\canopy-1.5.5.3123.win-x86_64\lib\site-packages\traits\trait_notifiers.py", line 340, in __call__
self.handler( *args )
File "build\bdist.win-amd64\egg\canopy\logging\logging_service.py", line 203, in _exception_added_fired
File "build\bdist.win-amd64\egg\canopy\logging\logging_service.py", line 187, in _report_exception
File "build\bdist.win-amd64\egg\canopy\feedback\data_reporter.py", line 505, in start
File "build\bdist.win-amd64\egg\canopy\feedback\data_reporter_view.py", line 192, in __init__
File "build\bdist.win-amd64\egg\canopy\feedback\data_reporter_view.py", line 221, in setup_ui
File "build\bdist.win-amd64\egg\canopy\feedback\data_reporter_view.py", line 304, in __init__
File "build\bdist.win-amd64\egg\canopy\feedback\data_reporter.py", line 269, in _requester_email_default
File "build\bdist.win-amd64\egg\canopy\feedback\data_reporter.py", line 261, in _account_service_default
File "build\bdist.win-amd64\egg\canopy\accounts\account_service.py", line 359, in __init__
File "C:\Users\charizard\AppData\Local\Enthought\Canopy\App\appdata\canopy-1.5.5.3123.win-x86_64\lib\site-packages\traits\has_traits.py", line 3285, in _init_trait_listeners
getattr( self, '_init_trait_%s_listener' % data[0] )( name, *data )
File "C:\Users\charizard\AppData\Local\Enthought\Canopy\App\appdata\canopy-1.5.5.3123.win-x86_64\lib\site-packages\traits\has_traits.py", line 3340, in _init_trait_delegate_listener
self.on_trait_change( notify, name_pattern, target=self )
File "C:\Users\charizard\AppData\Local\Enthought\Canopy\App\appdata\canopy-1.5.5.3123.win-x86_64\lib\site-packages\traits\has_traits.py", line 2584, in on_trait_change
listener.register( self )
File "C:\Users\charizard\AppData\Local\Enthought\Canopy\App\appdata\canopy-1.5.5.3123.win-x86_64\lib\site-packages\traits\traits_listener.py", line 433, in register
value = getattr( self, type )( new, name, False )
File "C:\Users\charizard\AppData\Local\Enthought\Canopy\App\appdata\canopy-1.5.5.3123.win-x86_64\lib\site-packages\traits\traits_listener.py", line 701, in _register_simple
return next.register( getattr( object, name ) )
File "build\bdist.win-amd64\egg\canopy\accounts\account_service.py", line 308, in _preferences_default
File "build\bdist.win-amd64\egg\canopy\accounts\account_service.py", line 314, in _enstaller_config_default
File "C:\Users\charizard\AppData\Local\Enthought\Canopy\App\appdata\canopy-1.5.5.3123.win-x86_64\lib\site-packages\enstaller\config.py", line 299, in from_file
ret = _create(fp)
File "C:\Users\charizard\AppData\Local\Enthought\Canopy\App\appdata\canopy-1.5.5.3123.win-x86_64\lib\site-packages\enstaller\config.py", line 268, in _create
parsed = parse_assignments(fp)
File "C:\Users\charizard\AppData\Local\Enthought\Canopy\App\appdata\canopy-1.5.5.3123.win-x86_64\lib\site-packages\egginst\utils.py", line 207, in parse_assignments
return _AssignmentParser().parse(file_or_filename.read())
File "C:\Users\charizard\AppData\Local\Enthought\Canopy\App\appdata\canopy-1.5.5.3123.win-x86_64\lib\site-packages\egginst\utils.py", line 172, in parse
root = ast.parse(s)
File "C:\Users\charizard\AppData\Local\Enthought\Canopy\App\appdata\canopy-1.5.5.3123.win-x86_64\lib\ast.py", line 37, in parse
return compile(source, filename, mode, PyCF_ONLY_AST)
TypeError: compile() expected string without null bytes
Exception occurred in traits notification handler for object: <canopy.logging.logging_service.LoggingService object at 0x00000000054EAA98>, trait: exception_added, old value: <undefined>, new value: <LogRecord: root, 40, build\bdist.win-amd64\egg\canopy\logging\logging_service.py, 154, "Uncaught exception captured">
Traceback (most recent call last):
File "C:\Users\charizard\AppData\Local\Enthought\Canopy\App\appdata\canopy-1.5.5.3123.win-x86_64\lib\site-packages\traits\trait_notifiers.py", line 340, in __call__
self.handler( *args )
File "build\bdist.win-amd64\egg\canopy\logging\logging_service.py", line 203, in _exception_added_fired
File "build\bdist.win-amd64\egg\canopy\logging\logging_service.py", line 187, in _report_exception
File "build\bdist.win-amd64\egg\canopy\feedback\data_reporter.py", line 505, in start
File "build\bdist.win-amd64\egg\canopy\feedback\data_reporter_view.py", line 192, in __init__
File "build\bdist.win-amd64\egg\canopy\feedback\data_reporter_view.py", line 221, in setup_ui
File "build\bdist.win-amd64\egg\canopy\feedback\data_reporter_view.py", line 304, in __init__
File "build\bdist.win-amd64\egg\canopy\feedback\data_reporter.py", line 269, in _requester_email_default
File "build\bdist.win-amd64\egg\canopy\feedback\data_reporter.py", line 261, in _account_service_default
File "build\bdist.win-amd64\egg\canopy\accounts\account_service.py", line 359, in __init__
File "C:\Users\charizard\AppData\Local\Enthought\Canopy\App\appdata\canopy-1.5.5.3123.win-x86_64\lib\site-packages\traits\has_traits.py", line 3285, in _init_trait_listeners
getattr( self, '_init_trait_%s_listener' % data[0] )( name, *data )
File "C:\Users\charizard\AppData\Local\Enthought\Canopy\App\appdata\canopy-1.5.5.3123.win-x86_64\lib\site-packages\traits\has_traits.py", line 3340, in _init_trait_delegate_listener
self.on_trait_change( notify, name_pattern, target=self )
File "C:\Users\charizard\AppData\Local\Enthought\Canopy\App\appdata\canopy-1.5.5.3123.win-x86_64\lib\site-packages\traits\has_traits.py", line 2584, in on_trait_change
listener.register( self )
File "C:\Users\charizard\AppData\Local\Enthought\Canopy\App\appdata\canopy-1.5.5.3123.win-x86_64\lib\site-packages\traits\traits_listener.py", line 433, in register
value = getattr( self, type )( new, name, False )
File "C:\Users\charizard\AppData\Local\Enthought\Canopy\App\appdata\canopy-1.5.5.3123.win-x86_64\lib\site-packages\traits\traits_listener.py", line 701, in _register_simple
return next.register( getattr( object, name ) )
File "build\bdist.win-amd64\egg\canopy\accounts\account_service.py", line 308, in _preferences_default
File "build\bdist.win-amd64\egg\canopy\accounts\account_service.py", line 314, in _enstaller_config_default
File "C:\Users\charizard\AppData\Local\Enthought\Canopy\App\appdata\canopy-1.5.5.3123.win-x86_64\lib\site-packages\enstaller\config.py", line 299, in from_file
ret = _create(fp)
File "C:\Users\charizard\AppData\Local\Enthought\Canopy\App\appdata\canopy-1.5.5.3123.win-x86_64\lib\site-packages\enstaller\config.py", line 268, in _create
parsed = parse_assignments(fp)
File "C:\Users\charizard\AppData\Local\Enthought\Canopy\App\appdata\canopy-1.5.5.3123.win-x86_64\lib\site-packages\egginst\utils.py", line 207, in parse_assignments
return _AssignmentParser().parse(file_or_filename.read())
File "C:\Users\charizard\AppData\Local\Enthought\Canopy\App\appdata\canopy-1.5.5.3123.win-x86_64\lib\site-packages\egginst\utils.py", line 172, in parse
root = ast.parse(s)
File "C:\Users\charizard\AppData\Local\Enthought\Canopy\App\appdata\canopy-1.5.5.3123.win-x86_64\lib\ast.py", line 37, in parse
return compile(source, filename, mode, PyCF_ONLY_AST)
TypeError: compile() expected string without null bytes
Please zip and email your file C:\Users\charizard\.enstaller4rc to support#enthought.com for forensics, and refer to this SO article. Then just delete that file, and I expect that you'll be able to start Canopy ok.
Related
Error Running Apache Beam with python via Dataflow runner
Description I am currently implementing a batch job with dataflow using apache beam, this works fine when i use direct runner. Changing this throws the below exception, not sure where the error is comming from. Code Snippet enter image description here Error: raceback (most recent call last): File "/usr/local/lib/python3.9/site-packages/beam_mysql/connector/client.py", line 179, in enter self.conn = mysql.connector.connect(**self._config) File "/usr/local/lib/python3.9/site-packages/mysql/connector/pooling.py", line 286, in connect return CMySQLConnection(*args, **kwargs) File "/usr/local/lib/python3.9/site-packages/mysql/connector/connection_cext.py", line 101, in init self.connect(**kwargs) File "/usr/local/lib/python3.9/site-packages/mysql/connector/abstracts.py", line 1095, in connect self._open_connection() File "/usr/local/lib/python3.9/site-packages/mysql/connector/connection_cext.py", line 268, in _open_connection raise get_mysql_exception( mysql.connector.errors.DatabaseError: 2003 (HY000): Can't connect to MySQL server on '127.0.0.1:41849' (111) During handling of the above exception, another exception occurred: Traceback (most recent call last): File "/usr/local/lib/python3.9/site-packages/apache_beam/runners/worker/sdk_worker.py", line 284, in _execute response = task() File "/usr/local/lib/python3.9/site-packages/apache_beam/runners/worker/sdk_worker.py", line 357, in lambda: self.create_worker().do_instruction(request), request) File "/usr/local/lib/python3.9/site-packages/apache_beam/runners/worker/sdk_worker.py", line 597, in do_instruction return getattr(self, request_type)( File "/usr/local/lib/python3.9/site-packages/apache_beam/runners/worker/sdk_worker.py", line 635, in process_bundle bundle_processor.process_bundle(instruction_id)) File "/usr/local/lib/python3.9/site-packages/apache_beam/runners/worker/bundle_processor.py", line 1003, in process_bundle input_op_by_transform_id[element.transform_id].process_encoded( File "/usr/local/lib/python3.9/site-packages/apache_beam/runners/worker/bundle_processor.py", line 227, in process_encoded self.output(decoded_value) File "apache_beam/runners/worker/operations.py", line 526, in apache_beam.runners.worker.operations.Operation.output File "apache_beam/runners/worker/operations.py", line 528, in apache_beam.runners.worker.operations.Operation.output File "apache_beam/runners/worker/operations.py", line 237, in apache_beam.runners.worker.operations.SingletonElementConsumerSet.receive File "apache_beam/runners/worker/operations.py", line 240, in apache_beam.runners.worker.operations.SingletonElementConsumerSet.receive File "apache_beam/runners/worker/operations.py", line 907, in apache_beam.runners.worker.operations.DoOperation.process File "apache_beam/runners/worker/operations.py", line 908, in apache_beam.runners.worker.operations.DoOperation.process File "apache_beam/runners/common.py", line 1419, in apache_beam.runners.common.DoFnRunner.process File "apache_beam/runners/common.py", line 1491, in apache_beam.runners.common.DoFnRunner._reraise_augmented File "apache_beam/runners/common.py", line 1417, in apache_beam.runners.common.DoFnRunner.process File "apache_beam/runners/common.py", line 623, in apache_beam.runners.common.SimpleInvoker.invoke_process File "apache_beam/runners/common.py", line 1581, in apache_beam.runners.common._OutputHandler.handle_process_outputs File "apache_beam/runners/common.py", line 1694, in apache_beam.runners.common._OutputHandler._write_value_to_tag File "apache_beam/runners/worker/operations.py", line 240, in apache_beam.runners.worker.operations.SingletonElementConsumerSet.receive File "apache_beam/runners/worker/operations.py", line 907, in apache_beam.runners.worker.operations.DoOperation.process File "apache_beam/runners/worker/operations.py", line 908, in apache_beam.runners.worker.operations.DoOperation.process File "apache_beam/runners/common.py", line 1419, in apache_beam.runners.common.DoFnRunner.process File "apache_beam/runners/common.py", line 1491, in apache_beam.runners.common.DoFnRunner._reraise_augmented File "apache_beam/runners/common.py", line 1417, in apache_beam.runners.common.DoFnRunner.process File "apache_beam/runners/common.py", line 623, in apache_beam.runners.common.SimpleInvoker.invoke_process File "apache_beam/runners/common.py", line 1581, in apache_beam.runners.common._OutputHandler.handle_process_outputs File "apache_beam/runners/common.py", line 1694, in apache_beam.runners.common._OutputHandler._write_value_to_tag File "apache_beam/runners/worker/operations.py", line 240, in apache_beam.runners.worker.operations.SingletonElementConsumerSet.receive File "apache_beam/runners/worker/operations.py", line 907, in apache_beam.runners.worker.operations.DoOperation.process File "apache_beam/runners/worker/operations.py", line 908, in apache_beam.runners.worker.operations.DoOperation.process File "apache_beam/runners/common.py", line 1419, in apache_beam.runners.common.DoFnRunner.process File "apache_beam/runners/common.py", line 1507, in apache_beam.runners.common.DoFnRunner._reraise_augmented File "apache_beam/runners/common.py", line 1417, in apache_beam.runners.common.DoFnRunner.process File "apache_beam/runners/common.py", line 623, in apache_beam.runners.common.SimpleInvoker.invoke_process File "apache_beam/runners/common.py", line 1571, in apache_beam.runners.common._OutputHandler.handle_process_outputs File "/usr/local/lib/python3.9/site-packages/apache_beam/runners/worker/bundle_processor.py", line 1454, in process for part, size in self.restriction_provider.split_and_size( File "/usr/local/lib/python3.9/site-packages/apache_beam/transforms/core.py", line 331, in split_and_size for part in self.split(element, restriction): File "/usr/local/lib/python3.9/site-packages/apache_beam/io/iobase.py", line 1641, in split estimated_size = restriction.source().estimate_size() File "/usr/local/lib/python3.9/site-packages/beam_mysql/connector/source.py", line 49, in estimate_size return self._splitter.estimate_size() File "/usr/local/lib/python3.9/site-packages/beam_mysql/connector/splitters.py", line 48, in estimate_size return self.source.client.rough_counts_estimator(self.source.query) File "/usr/local/lib/python3.9/site-packages/beam_mysql/connector/client.py", line 104, in rough_counts_estimator with _MySQLConnection(self._config) as conn: File "/usr/local/lib/python3.9/site-packages/beam_mysql/connector/client.py", line 182, in enter raise MySQLClientError(f"Failed to connect mysql, Raise exception: {e}") beam_mysql.connector.errors.MySQLClientError: Failed to connect mysql, Raise exception: 2003 (HY000): Can't connect to MySQL server on '127.0.0.1:36247' (111) [while running 'ref_AppliedPTransform_Read-From-Mysql-Read-SDFBoundedSourceReader-ParDo-SDFBoundedSourceDoFn-_7/SplitWithSizing-ptransform-38']
You have a connection problem to MySql : Your traceback indicates : mysql.connector.errors.DatabaseError: 2003 (HY000): Can't connect to MySQL server on '127.0.0.1:41849' https://dev.mysql.com/doc/refman/8.0/en/can-not-connect-to-server.html#:~:text=The%20error%20(2003)%20Can',one%20configured%20on%20the%20server. Check your connection to your MySql server please and also the parameters passed by your Beam job.
jupyter_client.kernelspec.NoSuchKernel: No such kernel named PySpark
Am trying to execute Jupyter notebook from command line. Am currently using the docker image provided in below link https://hub.docker.com/r/jupyter/pyspark-notebook When i try to execute below in command line it fails. jupyter nbconvert --to notebook --ExecutePreprocessor.kernel_name=PySpark --ExecutePreprocessor.timeout=3600 --execute notebooks/sample-notebook.ipynb Below is the error message [NbConvertApp] Converting notebook notebooks/sample-notebook.ipynb to notebook Traceback (most recent call last): File "/opt/conda/bin/jupyter-nbconvert", line 11, in <module> sys.exit(main()) File "/opt/conda/lib/python3.7/site-packages/jupyter_core/application.py", line 270, in launch_instance return super(JupyterApp, cls).launch_instance(argv=argv, **kwargs) File "/opt/conda/lib/python3.7/site-packages/traitlets/config/application.py", line 664, in launch_instance app.start() File "/opt/conda/lib/python3.7/site-packages/nbconvert/nbconvertapp.py", line 340, in start self.convert_notebooks() File "/opt/conda/lib/python3.7/site-packages/nbconvert/nbconvertapp.py", line 510, in convert_notebooks self.convert_single_notebook(notebook_filename) File "/opt/conda/lib/python3.7/site-packages/nbconvert/nbconvertapp.py", line 481, in convert_single_notebook output, resources = self.export_single_notebook(notebook_filename, resources, input_buffer=input_buffer) File "/opt/conda/lib/python3.7/site-packages/nbconvert/nbconvertapp.py", line 410, in export_single_notebook output, resources = self.exporter.from_filename(notebook_filename, resources=resources) File "/opt/conda/lib/python3.7/site-packages/nbconvert/exporters/exporter.py", line 179, in from_filename return self.from_file(f, resources=resources, **kw) File "/opt/conda/lib/python3.7/site-packages/nbconvert/exporters/exporter.py", line 197, in from_file return self.from_notebook_node(nbformat.read(file_stream, as_version=4), resources=resources, **kw) File "/opt/conda/lib/python3.7/site-packages/nbconvert/exporters/notebook.py", line 32, in from_notebook_node nb_copy, resources = super(NotebookExporter, self).from_notebook_node(nb, resources, **kw) File "/opt/conda/lib/python3.7/site-packages/nbconvert/exporters/exporter.py", line 139, in from_notebook_node nb_copy, resources = self._preprocess(nb_copy, resources) File "/opt/conda/lib/python3.7/site-packages/nbconvert/exporters/exporter.py", line 316, in _preprocess nbc, resc = preprocessor(nbc, resc) File "/opt/conda/lib/python3.7/site-packages/nbconvert/preprocessors/base.py", line 47, in __call__ return self.preprocess(nb, resources) File "/opt/conda/lib/python3.7/site-packages/nbconvert/preprocessors/execute.py", line 403, in preprocess with self.setup_preprocessor(nb, resources, km=km): File "/opt/conda/lib/python3.7/contextlib.py", line 112, in __enter__ return next(self.gen) File "/opt/conda/lib/python3.7/site-packages/nbconvert/preprocessors/execute.py", line 345, in setup_preprocessor self.km, self.kc = self.start_new_kernel(**kwargs) File "/opt/conda/lib/python3.7/site-packages/nbconvert/preprocessors/execute.py", line 291, in start_new_kernel km.start_kernel(extra_arguments=self.extra_arguments, **kwargs) File "/opt/conda/lib/python3.7/site-packages/jupyter_client/manager.py", line 301, in start_kernel kernel_cmd, kw = self.pre_start_kernel(**kw) File "/opt/conda/lib/python3.7/site-packages/jupyter_client/manager.py", line 254, in pre_start_kernel kernel_cmd = self.format_kernel_cmd(extra_arguments=extra_arguments) File "/opt/conda/lib/python3.7/site-packages/jupyter_client/manager.py", line 178, in format_kernel_cmd cmd = self.kernel_spec.argv + extra_arguments File "/opt/conda/lib/python3.7/site-packages/jupyter_client/manager.py", line 84, in kernel_spec self._kernel_spec = self.kernel_spec_manager.get_kernel_spec(self.kernel_name) File "/opt/conda/lib/python3.7/site-packages/jupyter_client/kernelspec.py", line 235, in get_kernel_spec raise NoSuchKernel(kernel_name) jupyter_client.kernelspec.NoSuchKernel: No such kernel named PySpark
django-simple-history 1.9 break unittests
When I run unittests with django-simple-history==1.6.0, it runs fine but with django-simple-history==1.9.0 it breaks the unittests. Any ideas how to fix this? Creating test database for alias 'default'... Traceback (most recent call last): File "manage.py", line 12, in <module> execute_from_command_line(sys.argv) File "/home/me/venv/lib/python2.7/site-packages/django/core/management/__init__.py", line 338, in execute_from_command_line utility.execute() File "/home/me/venv/lib/python2.7/site-packages/django/core/management/__init__.py", line 330, in execute self.fetch_command(subcommand).run_from_argv(self.argv) File "/home/me/venv/lib/python2.7/site-packages/django/core/management/commands/test.py", line 30, in run_from_argv super(Command, self).run_from_argv(argv) File "/home/me/venv/lib/python2.7/site-packages/django/core/management/base.py", line 390, in run_from_argv self.execute(*args, **cmd_options) File "/home/me/venv/lib/python2.7/site-packages/django/core/management/commands/test.py", line 74, in execute super(Command, self).execute(*args, **options) File "/home/me/venv/lib/python2.7/site-packages/django/core/management/base.py", line 441, in execute output = self.handle(*args, **options) File "/home/me/venv/lib/python2.7/site-packages/django/core/management/commands/test.py", line 90, in handle failures = test_runner.run_tests(test_labels) File "/home/me/venv/lib/python2.7/site-packages/django/test/runner.py", line 210, in run_tests old_config = self.setup_databases() File "/home/me/venv/lib/python2.7/site-packages/django/test/runner.py", line 166, in setup_databases **kwargs File "/home/me/venv/lib/python2.7/site-packages/django/test/runner.py", line 370, in setup_databases serialize=connection.settings_dict.get("TEST", {}).get("SERIALIZE", True), File "/home/me/venv/lib/python2.7/site-packages/django/db/backends/base/creation.py", line 376, in create_test_db self.connection._test_serialized_contents = self.serialize_db_to_string() File "/home/me/venv/lib/python2.7/site-packages/django/db/backends/base/creation.py", line 413, in serialize_db_to_string serializers.serialize("json", get_objects(), indent=None, stream=out) File "/home/me/venv/lib/python2.7/site-packages/django/core/serializers/__init__.py", line 129, in serialize s.serialize(queryset, **options) File "/home/me/venv/lib/python2.7/site-packages/django/core/serializers/base.py", line 52, in serialize for obj in queryset: File "/home/me/venv/lib/python2.7/site-packages/django/db/backends/base/creation.py", line 409, in get_objects for obj in queryset.iterator(): File "/home/me/venv/lib/python2.7/site-packages/django/db/models/query.py", line 238, in iterator results = compiler.execute_sql() File "/home/me/venv/lib/python2.7/site-packages/django/db/models/sql/compiler.py", line 829, in execute_sql cursor.execute(sql, params) File "/home/me/venv/lib/python2.7/site-packages/django/db/backends/utils.py", line 64, in execute return self.cursor.execute(sql, params) File "/home/me/venv/lib/python2.7/site-packages/django/db/utils.py", line 97, in __exit__ six.reraise(dj_exc_type, dj_exc_value, traceback) File "/home/me/venv/lib/python2.7/site-packages/django/db/backends/utils.py", line 64, in execute return self.cursor.execute(sql, params) File "/home/me/venv/lib/python2.7/site-packages/django/db/backends/sqlite3/base.py", line 318, in execute return Database.Cursor.execute(self, query, params) django.db.utils.OperationalError: no such column: myapp_historicalbook.history_change_reason
I got it. I had to remove my migration folder in order to be able to run the unit tests.
WARNING: Readline services not available or not loaded.AttributeError: 'module' object has no attribute 'set_completer_delims'
REPL run ipython an error occurred. WARNING: Readline services not available or not loaded. Traceback (most recent call last): File "C:\Program Files\Sublime Text 3\Data\Packages/SublimeREPL/config/Python/ipy_repl.py", line 52, in <module> embedded_shell.initialize() File "<string>", line 2, in initialize File "D:\Python27\lib\site-packages\IPython\config\application.py", line 75, in catch_config_error return method(app, *args, **kwargs) File "D:\Python27\lib\site-packages\IPython\terminal\ipapp.py", line 332, in initialize self.init_shell() File "D:\Python27\lib\site-packages\IPython\terminal\console\app.py", line 114, in init_shell client=self.kernel_client, File "D:\Python27\lib\site-packages\IPython\config\configurable.py", line 337, in instance inst = cls(*args, **kwargs) File "D:\Python27\lib\site-packages\IPython\core\interactiveshell.py", line 524, in __init__ self.init_completer() File "D:\Python27\lib\site-packages\IPython\terminal\console\interactiveshell.py", line 129, in init_completer self.Completer = ZMQCompleter(self, self.client, config=self.config) File "D:\Python27\lib\site-packages\IPython\terminal\console\completer.py", line 37, in __init__ self.readline.set_completer_delims('\r\n') AttributeError: 'module' object has no attribute 'set_completer_delims'
I experienced this problem whilst running ipython console in the WinPython distribution. In my case the problem was fixed by installing pyreadline: pip install pyreadline Hope this works for you too.
ipython: OperationalError: disk I/O error
I was running ipython successfully on fedora 18 until now: I'm getting the following exception when trying to launch it: Traceback (most recent call last): File "/usr/bin/ipython", line 9, in <module> load_entry_point('ipython==1.1.0', 'console_scripts', 'ipython')() File "/usr/lib/python2.7/site-packages/IPython/__init__.py", line 118, in start_ipython return launch_new_instance(argv=argv, **kwargs) File "/usr/lib/python2.7/site-packages/IPython/config/application.py", line 544, in launch_instance app.initialize(argv) File "<string>", line 2, in initialize File "/usr/lib/python2.7/site-packages/IPython/config/application.py", line 89, in catch_config_error return method(app, *args, **kwargs) File "/usr/lib/python2.7/site-packages/IPython/terminal/ipapp.py", line 323, in initialize self.init_shell() File "/usr/lib/python2.7/site-packages/IPython/terminal/ipapp.py", line 339, in init_shell ipython_dir=self.ipython_dir, user_ns=self.user_ns) File "/usr/lib/python2.7/site-packages/IPython/config/configurable.py", line 349, in instance inst = cls(*args, **kwargs) File "/usr/lib/python2.7/site-packages/IPython/terminal/interactiveshell.py", line 320, in __init__ **kwargs File "/usr/lib/python2.7/site-packages/IPython/core/interactiveshell.py", line 456, in __init__ self.init_history() File "/usr/lib/python2.7/site-packages/IPython/core/interactiveshell.py", line 1487, in init_history self.history_manager = HistoryManager(shell=self, parent=self) File "/usr/lib/python2.7/site-packages/IPython/core/history.py", line 481, in __init__ self.new_session() File "<string>", line 2, in new_session File "/usr/lib/python2.7/site-packages/IPython/core/history.py", line 65, in needs_sqlite return f(self, *a, **kw) File "/usr/lib/python2.7/site-packages/IPython/core/history.py", line 500, in new_session self.session_number = cur.lastrowid OperationalError: disk I/O error If you suspect this is an IPython bug, please report it at: https://github.com/ipython/ipython/issues or send an email to the mailing list at ipython-dev#scipy.org You can print a more detailed traceback right now with "%tb", or use "%debug" to interactively debug it. Extra-detailed tracebacks for bug-reporting purposes can be enabled via: c.Application.verbose_crash=True I tried to upgrade ipython to the latest version using pip, which did not help. Any solution or workaround is very much welcomed.
IPython store history in a profile generally in ~/.ipython/profile_default/history.sqlite. There seem to be a disk error reading/writting to it. Check the permissions of the file/folders, if necessary delete the file.
I solved it by set c.NotebookNotary.db_file = u':memory:' in jupyter configure file ~/.jupyter/jupyter_notebook_config.py