Skip to content

update test_utils#1752

Open
SFJohnson24 wants to merge 1 commit into
mainfrom
unittest
Open

update test_utils#1752
SFJohnson24 wants to merge 1 commit into
mainfrom
unittest

Conversation

@SFJohnson24
Copy link
Copy Markdown
Collaborator

Fixed Windows-specific subprocess failures in test_utils.py by setting PYTHONUNBUFFERED=1 and PYTHONUTF8=1 in the child process environment.

  • PYTHONUNBUFFERED=1 prevents the child process from holding stderr in memory and ensures it gets written out before the process ends
  • PYTHONUTF8=1 ensures output is written in UTF-8 rather than the Windows system codepage (CP1252).

Environment changes are applied to a copy of the parent environment to avoid mutation.

Copy link
Copy Markdown
Collaborator

@RamilCDISC RamilCDISC left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The PR updates test_utils subprocess command to use environment which write b ack to parent process and in proper readable format. The passing CI ensures that the changes integrate properly.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

unit tests are failing on windows in non-debug mode

3 participants