Message 350569 - Python tracker
Oh yeah, that locale_alias table is useless on Windows :( But at least the function is documented in such a way that we can change it: "The returned locale code is formatted for use with :func:`setlocale`." Alternatively, we could make setlocale() do its own normalization step on Windows and ignore (or otherwise validate/reject) the encoding. None of that explains why the test doesn't seem to run at all on the buildbots though.