To reproduce:
- Edit a key with a "Herp Derp" uid
- adduid a new "Herp Derp" uid
- uid 1 and deluid
- Now you correctly see only one uid, great. save
- gpg -K and... surprise, your secret key has no uid, while your public key does
An edge case, I know. But might happen if one wants to refresh (delete and recreate) a uid for some reason.
Probably has to do with the "duplicated user ID detected - merged" feature.