This is hardly a bug but is a little annoying.
The environment variable set by gedit: GEDIT_CURRRENT_DOCUMENT_LANGUAGE has three Rs in the word CURRENT.
GEDIT_CURRRENT_DOCUMENT_LANGUAGE
CURRENT
Found in gedit version 3.22.1 on openSUSE.
3.22.1
Image