hey there,
bug as is says on the tin. examples:
gpg --list-packets /tmp/nouid.sec.asc # off=0 ctb=95 tag=5 hlen=3 plen=966 :secret key packet: version 4, algo 1, created 1497283586, expires 0 pkey[0]: [2048 bits] pkey[1]: [17 bits] iter+salt S2K, algo: 9, SHA1 protection, hash: 10, salt: 384F0480B89CE5CB protect count: 524288 (144) protect IV: 10 5c be b7 83 e5 a5 fd df 16 17 c8 90 3b 7f a0 skey[2]: [v4 protected] keyid: 1316CE9CF807975D # off=969 ctb=b4 tag=13 hlen=2 plen=0 :user ID packet: "" # off=971 ctb=89 tag=2 hlen=3 plen=304 :signature packet: algo 1, keyid 1316CE9CF807975D version 4, created 1497283586, md5len 0, sigclass 0x13 digest algo 10, begin of digest 94 04 hashed subpkt 11 len 3 (pref-sym-algos: 9 8 7) hashed subpkt 21 len 1 (pref-hash-algos: 10) hashed subpkt 22 len 1 (pref-zip-algos: 1) hashed subpkt 25 len 1 (primary user ID) critical hashed subpkt 2 len 4 (sig created 2017-06-12) critical hashed subpkt 30 len 1 (features: 01) critical hashed subpkt 27 len 1 (key flags: 03) subpkt 16 len 8 (issuer key ID 1316CE9CF807975D) data: [2047 bits] # off=1278 ctb=9d tag=7 hlen=3 plen=966 :secret sub key packet: version 4, algo 1, created 1497283586, expires 0 pkey[0]: [2048 bits] pkey[1]: [17 bits] iter+salt S2K, algo: 9, SHA1 protection, hash: 10, salt: 603D070159508257 protect count: 524288 (144) protect IV: 64 00 dd dd fb 1b 83 e4 8e b3 e0 ea ba 08 8b b4 skey[2]: [v4 protected] keyid: 36FD61CA22B8B20D # off=2247 ctb=89 tag=2 hlen=3 plen=287 :signature packet: algo 1, keyid 1316CE9CF807975D version 4, created 1497283586, md5len 0, sigclass 0x18 digest algo 10, begin of digest 82 d1 critical hashed subpkt 2 len 4 (sig created 2017-06-12) critical hashed subpkt 27 len 1 (key flags: 04) subpkt 16 len 8 (issuer key ID 1316CE9CF807975D) data: [2047 bits]
gpg --no-default-keyring --keyring=/tmp/tmp.AY9CZfDrkq --import /tmp/nouid.sec.asc gpg: [don't know]: indeterminate length for invalid packet type 13 gpg: keyring_get_keyblock: read error: Invalid packet gpg: keydb_get_keyblock failed: Invalid keyring gpg: keydb_search failed: Invalid keyring gpg: key 0x1316CE9CF807975D: public key "[User ID not found]" imported gpg: [don't know]: indeterminate length for invalid packet type 13 gpg: keyring_get_keyblock: read error: Invalid packet gpg: keydb_get_keyblock failed: Invalid keyring gpg: keydb_search failed: Invalid keyring gpg: key 0x1316CE9CF807975D: failed to re-lookup public key gpg: Total number processed: 1 gpg: imported: 1 gpg: secret keys read: 1
the key is apparently imported, and will keep causing errors while listing keys. I was unable to delete it with --delete-keys, too.