Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Hitting Ctrl-C in dpython exits the process #62

Open
dowski opened this issue Mar 19, 2013 · 0 comments
Open

Hitting Ctrl-C in dpython exits the process #62

dowski opened this issue Mar 19, 2013 · 0 comments

Comments

@dowski
Copy link
Member

dowski commented Mar 19, 2013

$ dpython
[2013/03/19 05:40:35] {diesel} WARNING:Starting diesel <hand-rolled select.epoll>
Python 2.7.1+ (r271:86832, Sep 27 2012, 21:12:17)
[GCC 4.5.2] on linux2
Type "help", "copyright", "credits" or "license" for more information.
(InteractiveConsole)
>>> import diesel
>>> diesel.wait('for-something')
^C[2013/03/19 05:40:57] {diesel} WARNING:-- KeyboardInterrupt raised.. exiting main loop --
[2013/03/19 05:40:57] {diesel} INFO:Ending diesel application
$

This doesn't happen in the standard Python interpreter when a blocking operation is in progress. It just interrupts the operation and you can continue on your merry way.

$ python
Python 2.7.1+ (r271:86832, Sep 27 2012, 21:12:17)
[GCC 4.5.2] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> import time
>>> time.sleep(10)
^CTraceback (most recent call last):
  File "<stdin>", line 1, in <module>
KeyboardInterrupt
>>>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant