Skip to content

Commit 9256254

Browse files
miss-islingtonyihong0618kumaraditya303
authored
[3.14] gh-139845: do not print twice in default asyncio REPL (GH-139846) (#139859)
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 8761d6e commit 9256254

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
@@ -74,7 +74,8 @@ def callback():
7474
return
7575
except BaseException:
7676
if keyboard_interrupted:
77-
self.write("\nKeyboardInterrupt\n")
77+
if not CAN_USE_PYREPL:
78+
self.write("\nKeyboardInterrupt\n")
7879
else:
7980
self.showtraceback()
8081
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)