Commit de5c162
committed
fix(python): remove hardcoded OTEL_LOG_LEVEL=DEBUG that caused stderr deadlocks
Per #3357, `python.runScript()` deadlocks any Python subprocess
that writes more than ~64KB to stderr. The previous implementation
hardcoded `OTEL_LOG_LEVEL: 'DEBUG'` in the subprocess environment,
which caused OTEL-aware Python libraries (mlflow, opentelemetry-sdk,
etc.) to emit verbose debug-level logs to stderr during import.
Once stderr exceeded the OS pipe buffer, the Python process would
block on its next `write()` syscall indefinitely — a silent,
permanent hang with no error or timeout (unless `maxDuration` was
set).
Remove the hardcoded `OTEL_LOG_LEVEL: 'DEBUG'`. This brings
`runScript()` in line with `run()`, `runInline()`, and the
streaming variants — none of which set `OTEL_LOG_LEVEL`. The
original line was almost certainly leftover dev instrumentation
that shipped accidentally.
Closes #33571 parent 097fab0 commit de5c162
File tree
2 files changed
+5
-1
lines changed- .changeset
- packages/python/src
2 files changed
+5
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
97 | 97 | | |
98 | 98 | | |
99 | 99 | | |
100 | | - | |
101 | 100 | | |
102 | 101 | | |
103 | 102 | | |
| |||
0 commit comments