Skip to content

fix: dropdown search crash#3799

Merged
camdecoster merged 5 commits into
plotly:devfrom
AnnMarieW:fix-dropdown-search-crash
May 29, 2026
Merged

fix: dropdown search crash#3799
camdecoster merged 5 commits into
plotly:devfrom
AnnMarieW:fix-dropdown-search-crash

Conversation

@AnnMarieW
Copy link
Copy Markdown
Collaborator

closes #3707

This fixes a virtualization issue introduced in Dash 4.1 for large searchable option lists with component labels.

react-window uses the row index as the default key. After filtering, the same index may point to a different option, causing stale component rows to be reused. With component labels rendered through ExternalWrapper, this could result in errors like:

Cannot read properties of undefined (reading 'props')

Adding a stable itemKey based on the option value makes sure the rows are remounted correctly when the filtered options change.

@camdecoster
Copy link
Copy Markdown
Contributor

Good find! Could you double check linting? Once that's fixed, I'll approve and this can be merged.

@sonarqubecloud
Copy link
Copy Markdown

@camdecoster camdecoster merged commit 3ef77c5 into plotly:dev May 29, 2026
33 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[BUG] 4.1.0 dropdown search crash

2 participants