https://bugs.winehq.org/show_bug.cgi?id=55019
Bug ID: 55019 Summary: kernel32:process - Accents cause test_Environment() to fail on Windows Product: Wine Version: unspecified Hardware: x86-64 OS: Windows Status: NEW Severity: normal Priority: P2 Component: kernel32 Assignee: wine-bugs@winehq.org Reporter: fgouget@codeweavers.com
kernel32:process - Accents cause test_Environment() to fail on Windows:
process.c:1267: Test failed: Parent-env string CI_COMMIT_AUTHOR=Bernhard Klbl besentv@gmail.com isn't in child process process.c:1267: Test failed: Parent-env string CI_COMMIT_DESCRIPTION= Signed-off-by: Bernhard Klbl besentv@gmail.com isn't in child process process.c:1267: Test failed: Parent-env string CI_COMMIT_MESSAGE=mf/tests: Remove duplicate call to MFStartup(). Signed-off-by: Bernhard Klbl besentv@gmail.com isn't in child process process.c:1292: Test failed: Child-env string CI_COMMIT_AUTHOR=Bernhard K"lbl besentv@gmail.com isn't in parent process process.c:1292: Test failed: Child-env string CI_COMMIT_DESCRIPTION= Signed-off-by: Bernhard K"lbl besentv@gmail.com isn't in parent process process.c:1292: Test failed: Child-env string CI_COMMIT_MESSAGE=mf/tests: Remove duplicate call to MFStartup(). Signed-off-by: Bernhard K"lbl besentv@gmail.com isn't in parent process
See https://test.winehq.org/data/patterns.html#kernel32:process
These failures happen in about 15% of the runs and in all of them the environment variable was supposed to contain an accent.
This also explains why the failures: * Are always about the GitLab environment variables: in our regular test configurations environment variables don't contain accents. * Only happen on the GitLab CI Windows test VM: this VM is the only one where the environment variables change from one run to the next, mostly due to CI_COMMIT_XXX. * Always happen in both the 32- and 64-bit tests of a given build.
https://bugs.winehq.org/show_bug.cgi?id=55019
François Gouget fgouget@codeweavers.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Keywords| |source, testcase
https://bugs.winehq.org/show_bug.cgi?id=55019
Eric Pouech eric.pouech@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |eric.pouech@gmail.com
--- Comment #1 from Eric Pouech eric.pouech@gmail.com --- cannot repro from unix env... so if env var is correctly imported in unicode, the test looks ok
from gitlab docs: CI_ variables are always encoded in UTF-8 whatever the system windows default encoding is... (didn't check but likely the windows vm is set to cp 437?) so that's maybe the point
some options to test: - either use 'chcp 65001' before running winetest (likely in a cmd), but will fail if other env var are encoded in different CP (with values out of ansi 7 range) - or unset every CI_ env vars before running winetest - or set the vm cp to utf8...
https://bugs.winehq.org/show_bug.cgi?id=55019
--- Comment #2 from François Gouget fgouget@codeweavers.com --- The GitLab CI VMs use the default English locales so the codepage is 1252:
SystemDefaultLCID 0409 UserDefaultLCID 0409 ThreadLocale 0409 SystemPreferredUILanguages 0409 UserDefaultUILanguage 0409 ThreadUILanguage 0409 KeyboardLayout 04090409 Country 244 ACP 1252
I think the test should take into the case where an environment variable contains a badly encoded string and adjust its expectations accordingly.
This is even something that it should test by itself. After all we know this is something that can happen in the wild, to all the Windows GitLab CI users for instance. Testing this explicitly will also automatically produce results in all the locales tested by the Testbot, including ones with a UTF-8 code page.
https://bugs.winehq.org/show_bug.cgi?id=55019
--- Comment #3 from Eric Pouech eric.pouech@gmail.com --- I didn't want to spend too much on time on this, but may be I will. I just don't exactly get why we get different ansi strings in child and parent
and I don't like GitLab saying that it doesn't take care of current user's encoding and let the readers of its env variable to know which encoding they are made up
if the test fails under windows (ie not ensuring parent/child continuity in env / variables values), this means that the input is broken as not supported on windows, not the test
http://bugs.winehq.org/show_bug.cgi?id=55019
Bernhard Übelacker bernhardu@mailbox.org changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |bernhardu@mailbox.org
--- Comment #4 from Bernhard Übelacker bernhardu@mailbox.org --- This got now committed: https://gitlab.winehq.org/wine/wine/-/commit/86a72fd712d8f453b6b39e47c2eb767...
It filters out CI_COMMIT_AUTHOR and GITLAB_USER_NAME.
But now while attempting to close this bug, I realize the fields CI_COMMIT_DESCRIPTION and CI_COMMIT_MESSAGE are also controlled by the patch author and may contain non-ascii characters.
Without the need for the Signed-off-by this may be less likely, but should we clear those two variables too?
http://bugs.winehq.org/show_bug.cgi?id=55019
--- Comment #5 from Eric Pouech eric.pouech@gmail.com --- usually the description is in English, so shouldn't matter (too much) as noticed the commit body could have non ascii characters (so should be cleared too)
http://bugs.winehq.org/show_bug.cgi?id=55019
Bernhard Übelacker bernhardu@mailbox.org changed:
What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |RESOLVED Fixed by SHA1| |11aae16a340c2a03ded917d4395 | |3f04ce0bf8622 Resolution|--- |FIXED
--- Comment #6 from Bernhard Übelacker bernhardu@mailbox.org --- The variables I missed in the first patch got now committed in: https://gitlab.winehq.org/wine/wine/-/commit/11aae16a340c2a03ded917d43953f04...
Marking resolved-fixed.
http://bugs.winehq.org/show_bug.cgi?id=55019
Alexandre Julliard julliard@winehq.org changed:
What |Removed |Added ---------------------------------------------------------------------------- Status|RESOLVED |CLOSED
--- Comment #7 from Alexandre Julliard julliard@winehq.org --- Closing bugs fixed in 10.11.