CI failure in opensuse mingw64 cmake debug, possibly related to: Failed to determine console output code page
Job #52256626 failed for c807028d. All the GLib-based tests seem to be failing for opensuse mingw64 cmake debug
.
They emit this warning, which might be related:
15: GLib-WARNING (recursed) **: Failed to determine console output code page: Invalid access.. Falling back to UTF-8
debian mingw32 meson
is running at least a subset of these tests (at least corrupt
gets run) and does not have the same problem. This might be because it's using a different GLib version, or maybe it has different environment variables or something?
What GLib is trying to do here is:
locale = g_getenv ("LANG");
if (locale != NULL && locale[0] != '\0')
...
/* next try querying console codepage using native win32 API */
if (raw == NULL)
{
cp = GetConsoleOutputCP ();
if (cp)
{
sprintf (buf, "CP%u", cp);
raw = buf;
}
else if (GetLastError () != ERROR_INVALID_HANDLE)
{
gchar *emsg = g_win32_error_message (GetLastError ());
g_warning ("Failed to determine console output code page: %s. "
"Falling back to UTF-8", emsg);
g_free (emsg);
}
}
so maybe we can work around this with export LANG=C.UTF-8
or export LC_ALL=C.UTF-8
or something similar.