Open
Description
Bug description
The UI dialog for adding an annotation layer frequently is unresponsive in 4.0.0. By that, I mean that clicking on the Apply or OK buttons on this dialog does not work.

When trying to click Apply, the following error appears in the Javascript Console:

How to reproduce the bug
I experience this using the production version of the official Docker build of 4.0.0. apache/superset:4.0.0
I have run into this under different circumstances. It happens > 50% of the time but tends not to happen when creating new charts for the first time. So, try a variation of 1.:
- Go to the Charts list and click into an existing Line or Mixed chart.
- or, go to a Dashboard, click to edit a Line or Mixed chart on the dashboard
- Try to add an annotation layer from a Superset annotation
- Fill out the pop up box and try clicking Apply, or OK.
Screenshots/recordings
Please see the screenshots in the Bug description area above.
Superset version
4.0.0
Python version
3.10
Node version
16
Browser
Chrome
Additional context
This appears to be a React error.
These are the only feature flags I have manually set:
"TAGGING_SYSTEM": True,
"DASHBOARD_RBAC": True,
Checklist
- I have searched Superset docs and Slack and didn't find a solution to my problem.
- I have searched the GitHub issue tracker and didn't find a similar bug report.
- I have checked Superset's logs for errors and if I found a relevant Python stacktrace, I included it here as text in the "additional context" section.