The workaround works for me on 1.18.1! (I'm using Ubuntu MATE 20.04)
XMODIFIERS="@im=null" minecraft-launcherI was seemingly unable to get the game to pick up a patched (or updated) copy of libglfw, however.
This bug is still present; please re-open.
When combined with the so-called "void trading" glitch (not sure if there's an open ticket for that yet), this escalates into a tantamout-to-dupe as you can go back and forth between the librarian and cartographer and in a single in-game day have essentially as many emeralds as you desire