Closed Bug 1709690 Opened 4 years ago Closed 4 years ago

[wpt-sync] Sync PR 28849 - Fix setting os.environ["PATH"] to a binary string

Categories

(Testing :: web-platform-tests, task, P4)

task

Tracking

(firefox90 fixed)

RESOLVED FIXED
90 Branch
Tracking Status
firefox90 --- fixed

People

(Reporter: wpt-sync, Unassigned)

References

()

Details

(Whiteboard: [wptsync downstream])

Sync web-platform-tests PR 28849 into mozilla-central (this bug is closed when the sync is complete).

PR: https://github.com/web-platform-tests/wpt/pull/28849
Details from upstream follow.

b'Philip J\xc3\xa4genstedt <philip@foolip.org>' wrote:

Fix setting os.environ["PATH"] to a binary string

This code would raise "TypeError: str expected, not bytes" is run using
Python 3, since setting os.environ keys implictly encodes using
sys.getfilesystemencoding():
https://docs.python.org/3/library/os.html#os.environ

This might be dead code, or simply not exercised in wpt's CI.

Spotted while preparing https://github.com/web-platform-tests/wpt/pull/28848.

Pushed by wptsync@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/b6d7a02c97aa [wpt PR 28849] - Fix setting os.environ["PATH"] to a binary string, a=testonly
Test result changes from PR not available.
Status: NEW → RESOLVED
Closed: 4 years ago
Resolution: --- → FIXED
Target Milestone: --- → 90 Branch
You need to log in before you can comment on or make changes to this bug.