I confirm what @Tlse-vins said, this is a current limitation of Gladys. When you delete a device, Gladys must delete all the states of that device.
However, if you have many states (probably your case), and your disk is not very fast (as is the case with a micro-SD), this deletion can be long, and is currently blocking, which makes Gladys unavailable during the deletion.
This is a real problem that I started to fix in Gladys Assistant v4.10.2 by improving the deletion of states, but only for the « Yes, keep states » button, not yet for the « Delete » button of a device. (See => Gladys Assistant v4.10.2 est disponible avec des corrections de performances et un bouton nettoyage de la base! )
When you delete a device, in your case it’s better to wait, and it can be long on slow disks…
Sorry for the bad experience you’re having, you are unfortunately hitting several « known » limitations of Gladys in a row, I can imagine your frustration!