[F] Fix #462 Python version prints Traceback on KeyboardInterrupt

This commit is contained in:
Azalea 2025-11-21 19:27:52 +08:00
parent 8046e9bab3
commit e816235637

View File

@ -25,4 +25,8 @@ def run_rust():
if __name__ == '__main__':
run_rust()
try:
run_rust()
except KeyboardInterrupt:
printc('&cThe program is interrupted by ^C, exiting...')
exit(0)