Skip to content

Commit 54f9613

Browse files
miss-islingtonyihong0618kumaraditya303
authored
[3.13] gh-139845: do not print twice in default asyncio REPL (GH-139846) (#139860)
gh-139845: do not print twice in default asyncio REPL (GH-139846) (cherry picked from commit a310b3a) Co-authored-by: yihong <[email protected]> Co-authored-by: Kumar Aditya <[email protected]>
1 parent 16d2e97 commit 54f9613

File tree

2 files changed

+3
-1
lines changed

2 files changed

+3
-1
lines changed

Lib/asyncio/__main__.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,8 @@ def callback():
7272
return
7373
except BaseException:
7474
if keyboard_interrupted:
75-
self.write("\nKeyboardInterrupt\n")
75+
if not CAN_USE_PYREPL:
76+
self.write("\nKeyboardInterrupt\n")
7677
else:
7778
self.showtraceback()
7879
return self.STATEMENT_FAILED
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
Fix to not print KeyboardInterrupt twice in default asyncio REPL.

0 commit comments

Comments
 (0)