Skip to content

Commit

Permalink
change sigint by raising a keyboard interrupt
Browse files Browse the repository at this point in the history
  • Loading branch information
saucoide committed Jan 25, 2025
1 parent a04c214 commit 1901ba8
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions Lib/_pyrepl/commands.py
Original file line number Diff line number Diff line change
Expand Up @@ -435,11 +435,9 @@ def do(self) -> None:
class help(Command):
def do(self) -> None:
import _sitebuiltins
import signal

if self.reader.help_mode:
self.reader.help_mode = False
signal.raise_signal(signal.SIGINT)
raise KeyboardInterrupt
else:
self.reader.help_mode = True
with self.reader.suspend():
Expand Down

0 comments on commit 1901ba8

Please sign in to comment.