-
-
Notifications
You must be signed in to change notification settings - Fork 2.3k
[BUG] 4.1.0 dropdown search crash #3707
Copy link
Copy link
Open
Description
Describe your context
dash 4.1.0
Describe the bug
When typing a subset search pattern that matches a large subset of the items, then it causes the dropdown to crash
Expected behavior
The filtered items should be visible instead of a crash
Minimal Working Code Example
from dash import Dash, dcc, html
app = Dash(__name__)
options = [
{"label": html.Div(["Item", html.Span(f"#{i}")]),
"value": f"item_{i}",
"search": f"item_#{i}"}
for i in range(1, 5001)
]
app.layout = html.Div(
[
html.H3("Dropdown that crashes after typing a number"),
dcc.Dropdown(
id="big-dropdown",
options=options,
value="item_1",
placeholder="Select an item",
searchable=True,
clearable=True,
style={"width": "500px"},
),
],
)
if __name__ == "__main__":
app.run(debug=True)
If you type a number in the dropdown search bar then the application crashes and the search input is frozen
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels