我在尝试启动iPython的笔记本时收到以下错误消息:
File "C:\Python34\lib\site-packages\ipykernel\kernelapp.py", line 326, in patch_io
faulthandler_register = faulthandler.register
AttributeError: 'module' object has no attribute 'register'
这是在python3.4下实现的。在Python文档中,我看到register is a documented method:
faulthandler.register(signum, file=sys.stderr, all_threads=True, chain=False)
Register a user signal: install a handler for the signum signal to dump the traceback of all threads, or of the current thread if all_threads is False, into file. Call the previous handler if chain is True.
但是,查看faulthandler模块,我没有看到列出的方法:
^{pr2}$我错过了什么?在
我刚刚遇到了相同的问题(python 3.5-64,windows,完全更新),您可以将ipykernel升级到更新版本(
>=4.3.1
)并解决了这个问题:pip install ipykernel upgrade
您也可以将其降级(到
<4.3
),但不建议降级。在ipykernel 4.3.0中有一个bug。它是在4.2.x周期中引入的,只影响windows用户。在
一个问题已经填充了on GitHub,它将在4.3.1中修复,该版本现已发布。在
如果您进一步阅读您引用的文档,您将看到
register
不适用于您的原因:相关问题 更多 >
编程相关推荐