This surfaces a bug in interface_gui.py, that passes on master but fails on 622df9e941dd55fc9b01125ea1de659ed6a9794e.
On CI, we set LC_ALL=C.UTF-8 in all scripts, so the locale is set in all tests, which means that we're not really testing this change.
When running this test locally on a Linux environment with LC_ALL unset and no nl_NL.UTF-8 locale installed, the interface_gui.py test fails. This is because in test_node.py:302, we set subp_env.setdefault("LC_ALL", "nl_NL.UTF-8"). On CI, this operation is a no-op because LC_ALL is always set, so the nl_NL.UTF-8 locale is never actually set. When it is actually set, and nl_NL.UTF-8 isn't installed on the machine, the test fails.
Tested in a debian:trixie container:
$ python3 build/test/functional/interface_gui.py
...
2026-10-14T14:57:03.224515Z TestFramework (INFO): PRNG seed is: 6521282163018713296
2026-10-14T14:57:03.276866Z TestFramework (INFO): Initializing test directory /tmp/bitcoin_func_test_nr9vej0d
2026-10-14T14:57:03.871440Z TestFramework (INFO): Test that bitcoin-gui starts up and can be stopped via RPC
2026-10-14T14:57:04.243870Z TestFramework (ERROR): Unexpected exception:
Traceback (most recent call last):
File "/Users/stickies-v/code/bitcoin/review/36524/test/functional/test_framework/test_framework.py", line 146, in main
self.run_test()
~~~~~~~~~~~~~^^
File "/Users/stickies-v/code/bitcoin/review/36524/build/test/functional/interface_gui.py", line 34, in run_test
self.stop_node(0)
~~~~~~~~~~~~~~^^^
File "/Users/stickies-v/code/bitcoin/review/36524/test/functional/test_framework/test_framework.py", line 527, in stop_node
self.nodes[i].stop_node(expected_stderr, wait=wait)
~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/stickies-v/code/bitcoin/review/36524/test/functional/test_framework/test_node.py", line 517, in stop_node
self.wait_until_stopped(expected_stderr=expected_stderr)
~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/stickies-v/code/bitcoin/review/36524/test/functional/test_framework/test_node.py", line 563, in wait_until_stopped
self.wait_until(lambda: self.is_node_stopped(**kwargs), timeout=timeout)
~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/stickies-v/code/bitcoin/review/36524/test/functional/test_framework/test_node.py", line 913, in wait_until
return wait_until_helper_internal(test_function, timeout=timeout, timeout_factor=self.timeout_factor, check_interval=check_interval)
File "/Users/stickies-v/code/bitcoin/review/36524/test/functional/test_framework/util.py", line 449, in wait_until_helper_internal
if predicate():
~~~~~~~~~^
File "/Users/stickies-v/code/bitcoin/review/36524/test/functional/test_framework/test_node.py", line 563, in <lambda>
self.wait_until(lambda: self.is_node_stopped(**kwargs), timeout=timeout)
~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^
File "/Users/stickies-v/code/bitcoin/review/36524/test/functional/test_framework/test_node.py", line 548, in is_node_stopped
raise AssertionError("Unexpected stderr {} != {}".format(stderr, expected_stderr))
AssertionError: Unexpected stderr Detected locale "C" with character encoding "ANSI_X3.4-1968", which is not UTF-8.
Qt depends on a UTF-8 locale, and has switched to "C.UTF-8" instead.
If this causes problems, reconfigure your locale. See the locale(1) manual
for more information.
The test runs fine with LC_ALL=C.UTF-8 python3 build/test/functional/interface_gui.py.
From #35551, it seems like we set a well-translated language to ensure that in a foreign locale, RPC strings still come through in English. If that's what we want to achieve, then perhaps we could e.g. add https://github.com/stickies-v/bitcoin/commit/a39fa5420ed965f8975221ce49bd813fac3aed61 as a minimal fix prior to this change?