This occurs any time that a custom event, attribute, type, role....
is created. You delete all instances of the custom entry but the
option remains in the drop-down list.
To get rid if them, create a .gramps (non-media) backup. Then create a
new empty database and import the backup. Any of the custom items that
are no longer being used will be deleted from the drop-down options.
Once you are satisfied with the new database, you can delete the old
database and rename the new one to your liking.
I routinely do this every few months just to keep things tidy,