add_vline fails in batch mode
还没有人认领这个 Issue。
评估
- 难度
- 3/5
- 预计耗时
- 1-2 天
- 新手友好度
- 48/100
- Issue 类型
- 缺陷
- 描述清晰度
- 描述清楚
- 活跃度
- 停滞
- 技术栈
- plotly, python
调研方向
先从 batch_update 上下文和 add_vline 示例开始,然后检查 plotly/basedatatypes.py 第 3995 行附近。将失败的批处理模式路径与正常工作的直接调用进行比较,并使用报告中的版本重现 TypeError。完成标准是 add_vline 在 fig.batch_update() 内正常工作且不会引发异常,同时保留现有的直接调用行为。
由索引模型根据 Issue 内容生成。
描述
I am using plotly 5.24.0 with python 3.10.12 in a vs-code interactive window.
The following example raises TypeError: unsupported operand type(s) for +=: 'NoneType' and 'str' in [...]/site-packages/plotly/basedatatypes.py:3995
import plotly.graph_objects as go
fig = go.Figure()
with fig.batch_update():
fig.add_vline(1)
The same example without batch mode works fine:
import plotly.graph_objects as go
fig = go.Figure()
fig.add_vline(1)
- 主要语言
- Python
- 星标
- 18.8k
- 派生
- 2.8k
- 平均合并
- 13 小时 41 分钟
- 30 天内合并 PR
- 21
贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
plotly/plotly.py 的其他 Issue
-
P3 size: 1 task
难度 2/5 1-3 小时 新手友好度 65/100
-
P3 size: 1 task
难度 2/5 1-3 小时 新手友好度 72/100
-
bug P1
难度 1/5 1 小时以内 新手友好度 68/100
-
feature P3
难度 2/5 1-3 小时 新手友好度 62/100
-
feature P3
难度 2/5 1-3 小时 新手友好度 72/100
相似的 Issue
-
essnmx good first issue
难度 1/5 1 小时以内 新手友好度 95/100
-
难度 2/5 1-3 小时 新手友好度 65/100
syfoud/Simulated_Scepter#174 ·
-
难度 2/5 1-3 小时 新手友好度 75/100
Giskard-AI/giskard-oss#2840 · 1 条评论 ·
-
A claim comment carrying the issue number is silently declined while the workflow reports success 未关闭area: repo bug perceived difficulty: 2
难度 2/5 1-3 小时 新手友好度 70/100
-
难度 2/5 1-3 小时 新手友好度 75/100
yeti-platform/yeti#1380 ·