Commit 23ea56e
committed
gh-46927: Prevent readline from overriding environment
Readline library will set the LINES and COLUMNS environment variables
during initialization. One might expect these variables to be updated
later on SIGWINCH, but this is not the case with cpython.
As a consequence, when the readline module is imported, any process
launched from cpython with the default environment will have LINES and
COLUMNS variables set, potentially to a wrong value.
Use the rl_change_environment global variable to disable this initial
setup of the environment variables.1 parent 945bf8c commit 23ea56e
2 files changed
Lines changed: 9 additions & 0 deletions
File tree
- Misc/NEWS.d/next/Core_and_Builtins
- Modules
Lines changed: 2 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1349 | 1349 | | |
1350 | 1350 | | |
1351 | 1351 | | |
| 1352 | + | |
| 1353 | + | |
| 1354 | + | |
| 1355 | + | |
| 1356 | + | |
| 1357 | + | |
| 1358 | + | |
1352 | 1359 | | |
1353 | 1360 | | |
1354 | 1361 | | |
| |||
0 commit comments