TUI | Crashes when spamming button/key binding action (Workaround solution for https://github.com/Textualize/textual/issues/5596 causes race condition)

Looks like the workaround solution for https://github.com/Textualize/textual/issues/5596 has an issue because it causes a race condition.

The button event handler can launch multiple workers (tasks) doing the same thing, which can lead to weird bugs and crashes.

It can be observed on the create_profile form when pressing "enter" quickly to proceed with the form. It can also be observed on the dashboard when spamming the "Lock" key.

Edited by Mateusz Żebrak