Skip to content

Commit bfb7bc0

Browse files
committed
Update 2 code files
Modified: • src/omnipkg/common_utils.py (+1/-1 lines) • src/omnipkg/isolation/worker_daemon.py (+2/-0 lines) [gitship-generated]
1 parent a5a4bfd commit bfb7bc0

2 files changed

Lines changed: 3 additions & 1 deletion

File tree

src/omnipkg/common_utils.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ def safe_print(*args, **kwargs):
5454
except:
5555
pass
5656

57-
except UnicodeEncodeError:
57+
except (UnicodeEncodeError, OSError):
5858
try:
5959
safe_args = []
6060
# Get shell encoding (often cp1252 on legacy Windows)

src/omnipkg/isolation/worker_daemon.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2342,6 +2342,8 @@ def _spawn_process(self):
23422342
# Tell the worker it's running inside the daemon so safe_input()
23432343
# activates the NEEDS_INPUT relay instead of calling input() directly.
23442344
env["OMNIPKG_DAEMON_WORKER"] = "1" # ADD THIS LINE
2345+
env["PYTHONIOENCODING"] = "utf-8"
2346+
env["PYTHONUTF8"] = "1"
23452347
# Inject the correct multiversion base so omnipkgLoader knows exactly where bubbles are
23462348
if self.multiversion_base:
23472349
env["OMNIPKG_MULTIVERSION_BASE"] = self.multiversion_base

0 commit comments

Comments
 (0)