v2.10.1: fails to start on Python 3.14
还没有人认领这个 Issue。
评估
调研方向
从报告中指出的 src/e3sm_quickview/view_manager.py 中的 asyncio.get_event_loop() 调用处开始,然后检查服务器如何启动,以及 wslink 如何处理事件循环设置。使用报告中的启动命令在 Python 3.14 上重现问题;当 quickview 启动时不再出现缺少事件循环的错误,即为完成。考虑按照建议将 Python 3.14 添加到 CI。
由索引模型根据 Issue 内容生成。
描述
We're testing e3sm-quickview 2.10.1 (from conda-forge) on Perlmutter, in the upcoming E3SM-Unified 1.14.0, which uses Python 3.14.7. Running quickview crashes on startup, before the server starts:
$ quickview
VTKStreaming Video encoding is NOT AVAILABLE (missing Python package)
Loading plugin : .../e3sm_quickview/plugins/eam_gridlines.py
Loading plugin : .../e3sm_quickview/plugins/eam_projection.py
Loading plugin : .../e3sm_quickview/plugins/eam_reader.py
Loading plugin : .../e3sm_quickview/plugins/eam_filters.py
Traceback (most recent call last):
File ".../bin/quickview", line 10, in <module>
sys.exit(main())
~~~~^^
File ".../e3sm_quickview/app.py", line 802, in main
app = EAMApp()
File ".../e3sm_quickview/app.py", line 75, in __init__
self.view_manager = ViewManager(self.server, self.source)
~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^
File ".../e3sm_quickview/view_manager.py", line 100, in __init__
self.loop = asyncio.get_event_loop()
~~~~~~~~~~~~~~~~~~~~~~^^
File ".../python3.14/asyncio/events.py", line 718, in get_event_loop
raise RuntimeError('There is no current event loop in thread %r.'
% threading.current_thread().name)
RuntimeError: There is no current event loop in thread 'MainThread'.
Cause: Starting with Python 3.14, asyncio.get_event_loop() raises RuntimeError when no loop is set, where earlier versions created one implicitly. ViewManager.__init__ (view_manager.py#L100) runs before trame/wslink have started a loop, so it fails. The same line is still on main.
Suggested fix: wslink 2.5.7 already handles this (wslink/core.py, wslink/server.py) with:
try:
self.loop = asyncio.get_event_loop()
except RuntimeError:
self.loop = asyncio.new_event_loop()
asyncio.set_event_loop(self.loop)
wslink then picks up the same loop when the server starts. We checked this by setting a loop before calling main():
python -c "import asyncio, sys; asyncio.set_event_loop(asyncio.new_event_loop()); from e3sm_quickview.app import main; sys.argv[0]='quickview'; sys.exit(main())" --server
With that, the server starts normally and prints the connection URL. Since requires-python = ">=3.10" allows 3.14, it may also be worth adding Python 3.14 to CI.
This looks related to #111 (event loop missing in debounce) but affects a different code path.
Environment:
- e3sm-quickview 2.10.1 (conda-forge, noarch)
- Python 3.14.7
- trame 4.0.0, trame-server 4.0.0, wslink 2.5.7
- NERSC Perlmutter login node (pm-cpu)
Drafted by Claude Code and @xylar together.
- 主要语言
- JavaScript
- 星标
- 3
- 派生
- 4
- 平均合并
- 11 小时 51 分钟
- 30 天内合并 PR
- 6
环境准备
这个项目没有提供开发容器、Dockerfile 或贡献指南,环境需要你自己搭建:先看它的 README,通用步骤见我们的新手贡献指南。
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
Kitware/QuickView 的其他 Issue
-
难度 3/5 1-2 天 新手友好度 55/100
-
not urgent
难度 4/5 3-5 天 新手友好度 48/100
-
Spherical projection: globe appears to zoom in or out when center latitude changes可能重新可做 @jourdain 于 56 天前认领,目前没有进行中的 PR。 未关闭not urgent
-
Map improvement: outlines of countries, states, etc.可能重新可做 @jourdain 于 57 天前认领,目前没有进行中的 PR。 未关闭not urgent
-
maintenance
难度 4/5 3-5 天 新手友好度 35/100
查看 Kitware/QuickView 的全部 Issue
相似的 Issue
-
Code Cleanup Dev Environment
难度 2/5 1-3 小时 新手友好度 78/100
ProjectSidewalk/SidewalkWebpage#5699 ·
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 68/100
zenstackhq/zenstack#2873 ·
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 78/100
Jason-Vaughan/TangleClaw#2195 ·
维护者通常 1 天内回复
-
permissions in review update icon/data
难度 2/5 1-3 小时 新手友好度 69/100
simple-icons/simple-icons#15062 ·
维护者通常 1 天内回复
-
难度 1/5 1-3 小时 新手友好度 78/100
githubnext/gh-aw-cao#16664 ·
维护者通常 1 天内回复