[BUG]: Sankey warning breaks in @plotly/d3-sankey v0.12.3
維護者通常 1 天內回覆
還沒有人認領這個 Issue。
評估
- 難度
- 3/5
- 預估耗時
- 1-2 天
- 新手友好度
- 55/100
- Issue 類型
- 缺陷
- 描述清晰度
- 基本清楚
- 活躍度
- 冷清
- 技術堆疊
- d3, javascript
研究方向
從 src/traces/sankey/render.js 中第 76-78 行附近的警告開始,然後將升級後的 @plotly/d3-sankey v0.12.3 padding API 與已佈局的節點位置進行比較。釐清應如何偵測有效 padding,或是否應移除警告,並驗證診斷行為是否與受限制的佈局一致。
由索引模型根據 Issue 內容生成。
描述
Description
The upgrade to @plotly/d3-sankey v0.12.3 (in #7830) will break the warning here:
if (sankey.nodePadding() < nodePad) {
Lib.warn('node.pad was reduced to ', sankey.nodePadding(), ' to fit within the figure.');
}
In @plotly/[email protected], calling sankey.nodePadding() after running the layout returned the effective (post-clamp) padding value. In 0.12.3 the getter returns the user-configured value instead, because upstream split the internal state into separate dy (configured) and py (effective) variables.
After the upgrade, sankey.nodePadding() always equals nodePad, so the comparison is never true and the warning never fires. The layout itself still clamps correctly - only the diagnostic is affected.
Notes
Options to address the issue:
- Remove the warning entirely
- Derive the effective padding from the laid-out node positions (e.g. measure the gap between consecutive nodes in the densest column)
- 主要語言
- JavaScript
- 星號
- 18.4k
- 分支
- 2k
- 平均合併
- 1 天 21 小時
- 30 天內合併 PR
- 18
環境準備
- 沒有 Dockerfile 或 Docker Compose 檔案
- 有 Pull Request 範本
- 閱讀貢獻指南
從這裡開始
- 先讀完整個 Issue,再讀專案的貢獻指南。
- 在 Issue 下留言說明你要接手 —— 這能避免兩個人做同樣的事。
- Fork 儲存庫,在一個分支上完成修改。
- 送出 Pull Request,並在描述裡引用這個 Issue 編號。
plotly/plotly.js 的其他 Issue
-
bug
難度 2/5 1-3 小時 新手友好度 78/100
維護者通常 1 天內回覆
-
chore P3 plotly-internal size: 3 task
難度 2/5 1-3 小時 新手友好度 77/100
plotly/plotly.js#8064 · 1 則留言 ·
維護者通常 1 天內回覆
-
chore P1 plotly-internal size: 1 task
難度 1/5 1 小時以內 新手友好度 82/100
維護者通常 1 天內回覆
-
chore P3 plotly-internal size: 1 task
難度 2/5 1-3 小時 新手友好度 65/100
維護者通常 1 天內回覆
-
bug
難度 2/5 1-3 小時 新手友好度 65/100
plotly/plotly.js#7648 · 3 則留言 ·
維護者通常 1 天內回覆
相似的 Issue
-
area:ui bug effort:low incomplete model:light plan planner:gpt-6-1-sol
難度 2/5 1-3 小時 新手友好度 85/100
維護者通常 1 天內回覆
-
難度 2/5 1-3 小時 新手友好度 75/100
維護者通常 1 天內回覆
-
documentation good first issue hacktoberfest size/small type/docs up-for-grabs
難度 2/5 1-3 小時 新手友好度 88/100
Redo-San/RedoSan-Authenticity#511 ·
維護者通常 1 天內回覆
-
help wanted python v9 cert scope: curriculum
難度 2/5 1-3 小時 新手友好度 75/100
freeCodeCamp/freeCodeCamp#70604 ·
維護者通常 1 天內回覆
-
type: bug
難度 2/5 1-3 小時 新手友好度 74/100
RocketChat/Rocket.Chat#42543 · 2 則留言 ·
維護者通常 1 天內回覆