[3.13] gh-102136: Add -m to options that work with -i (GH-119271) (GH-119285)

(cherry picked from commit 172690227e)

Co-authored-by: Melanie Arbor <hellomelaniec@gmail.com>
This commit is contained in:
Miss Islington (bot) 2025-04-08 12:31:47 +02:00 committed by GitHub
parent 5c658c11f7
commit d2ec87f740
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -290,9 +290,15 @@ Miscellaneous options
.. option:: -i
When a script is passed as first argument or the :option:`-c` option is used,
enter interactive mode after executing the script or the command, even when
:data:`sys.stdin` does not appear to be a terminal. The
Enter interactive mode after execution.
Using the :option:`-i` option will enter interactive mode in any of the following circumstances\:
* When a script is passed as first argument
* When the :option:`-c` option is used
* When the :option:`-m` option is used
Interactive mode will start even when :data:`sys.stdin` does not appear to be a terminal. The
:envvar:`PYTHONSTARTUP` file is not read.
This can be useful to inspect global variables or a stack trace when a script