internal relayout method called with undefined
Dieses Issue hat noch niemand übernommen.
- Vorherrschende Sprache
- JavaScript
- Sterne
- 18.3k
- Forks
- 2k
- Ø Merge
- 2 T. 12 Std.
- Gemergte PRs (30 T.)
- 28
Beschreibung
We have observed a relayout failure immediately after this warning:
WARN: Relayout fail. undefined undefined
Non-Error promise rejection captured with value: undefined
coming from: https://github.com/plotly/plotly.js/blob/24b6f75e2d3b58cb1cd9cdd850894720404373d3/src/plot_api/plot_api.js#L1774
I'm not sure which exact circumstances triggered this failure, but the relayout internal function probably should not reject if astr is undefined, as this simply means there is nothing to update (recording the warning seems fine as it helps to diagnose call sites which are not correctly omitting the relayout, but it should not cause the function to fail).
I suggest that this branch should return successfully after logging a warning if astr is undefined / null.
It would also be useful for diagnosing the root cause further if the warning could include a stack trace.
Plotly.js version: 2.26.2
Beitragsleitfaden
Erste Schritte
- Lies das ganze Issue und danach den Beitragsleitfaden des Projekts.
- Schreib ins Issue, dass du es übernimmst — das erspart doppelte Arbeit.
- Forke das Repository und arbeite in einem Branch.
- Öffne einen Pull Request, der die Issue-Nummer nennt.
Rechercherichtung
Beginne in src/plot_api/plot_api.js ungefähr bei Zeile 1774 und verfolge, wie ein undefined- oder null-Wert von astr die interne relayout-Funktion erreicht. Überprüfe das Warnverhalten und bestätige, dass dieser Pfad erfolgreich abgeschlossen wird, statt abzuweisen; berücksichtige, wie ein Stack Trace die Diagnose unterstützen würde, und prüfe das relevante relayout-Verhalten, bevor du den Abschluss definierst.
Vom Indexierungsmodell aus dem Issue-Text verfasst.
Bewertung
- Tech-Stack
- javascript
- Bereich
- data-visualization
- Issue-Typ
- Bug
- Schwierigkeit
- 3/5
- Geschätzter Aufwand
- 1-2 Tage
- Aktivitätsstatus
- Veraltet
- Klarheit
- Größtenteils klar
- Anfängerfreundlichkeit
- 45/100