If you have an item in your offhand slot and try to use /clear, it'll give you back the unknown error has occurred message. It will clear the rest of your inventory, but the offhand slot stays. My examples below use a map and planks but it works with any block or item.
Linked issues
Attachments
Comments 2
Ah, I didn't see that one. Mine should be marked as a duplicate of MC-82896.
Fixed in version MC-82896