This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author helpimnotdrowning
Recipients helpimnotdrowning
Date 2021-06-02.04:44:38
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1622609078.37.0.104205223264.issue44284@roundup.psfhosted.org>
In-reply-to
Content
To reproduce (at least on Windows 10 w/ Python 3.9.4):

1) Make a python file:

while True:
    print('hello')

2) Run the file via cmd
3) Edit the file (while it is still running):

while True:
    print('goodbye')
    print('hello')

then save it
4) ctrl+c in the cmd window to exit the script
5) The traceback will look something like this:

Traceback (most recent call last):
  File "dfbssss.py", line 2, in <module>
    print('goodbye')
KeyboardInterrupt

The traceback mentions the print('goodbye') even though it wasnt in the file when it was run. It still calls it line 2, which is the line the print('hello') was before adding the print('goodbye')
History
Date User Action Args
2021-06-02 04:44:38helpimnotdrowningsetrecipients: + helpimnotdrowning
2021-06-02 04:44:38helpimnotdrowningsetmessageid: <1622609078.37.0.104205223264.issue44284@roundup.psfhosted.org>
2021-06-02 04:44:38helpimnotdrowninglinkissue44284 messages
2021-06-02 04:44:38helpimnotdrowningcreate