fix(release-bubbles): guard handleMouseOut against ECharts state transition crash#119481
Closed
billyvg wants to merge 1 commit into
Closed
fix(release-bubbles): guard handleMouseOut against ECharts state transition crash#119481billyvg wants to merge 1 commit into
billyvg wants to merge 1 commit into
Conversation
…tions
ECharts crashes internally when `setOption` with `markArea: {data: []}` is called
during a chart state transition — e.g. while a concurrent lazyUpdate from
`handleMouseOver` is still being applied. The crash manifests as:
TypeError: Cannot read properties of undefined (reading 'get')
in `MarkerModel._mergeOption` when iterating series models.
Add an `isDisposed()` guard and wrap the `setOption` call in a try/catch
so transient chart state errors don't surface as user-visible crashes.
Fixes JAVASCRIPT-3AP8
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_014Ti4xAam9aMA4vPse1BLQu
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
Sentry issue: JAVASCRIPT-3AP8 — escalating, 296 events, 196 users affected.
Users hovering over release bubbles in the Explore → Releases view encounter an unhandled crash:
The crash originates deep in ECharts (
MarkerModel._mergeOption → ecModel.eachSeries → seriesModel.get) and bubbles up through ourhandleMouseOuthandler atuseReleaseBubbles.tsx:552.Root Cause
handleMouseOutcallsechartsInstance.setOption({series: [{id: BUBBLE_AREA_SERIES_ID, markArea: {data: []}}]}, {lazyUpdate: true})to clear the highlighted mark area when the mouse leaves a bubble.During this merge, ECharts iterates all series models and applies marker options. If a concurrent
lazyUpdatefromhandleMouseOveris still being processed, the chart's internal series model list can containundefinedentries, causing the crash.The stack trace confirms the path:
Fix
isDisposed()guard before callingsetOption, to handle the case where the chart instance has been torn down.setOptioncall in a try/catch to swallow transient state transition errors. If the clear fails, the mark area will be cleaned up on the next mouse interaction.Evidence
Session
Claude session: https://claude.ai/code/session_014Ti4xAam9aMA4vPse1BLQu
Generated by Claude Code