Some folks had managed to find semi-matching parts that had the right code but couldn’t be soldered to the board because of pin spacing. Another person took an entirely different grey code encoder and made a little board to translate it to the correct code.
Every couple years I’d come back to this project to see if any better repairs had been proposed, or maybe a new part was available.
At some point, though, I actually stumbled onto replacement encoders on eBay, the exact correct kind!