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
KeyboardInterrupt starts expensive background process #4
Comments
possibly fixed (forgot thread.join()). Can you try? |
hey @ulfaslak did you have time to test it? |
Sorry, baby fog, will try later! |
sure, no rush! baby's more important :)
… On Nov 19, 2018, at 13:40, Ulf Aslak ***@***.***> wrote:
Sorry, baby fog, will try later!
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub <#4 (comment)>, or mute the thread <https://github.com/notifications/unsubscribe-auth/AKOzvP5_zi5acIHqo8XSGS1bjO_FhrVvks5uwqargaJpZM4YZq9D>.
|
Alright, it was fast enough to try. So I upgraded with pip to v0.0.6 (right one?), but the bug is still there. |
Haven't updated in pip yet, you'd have to install from a cloned repo ..
… On Nov 19, 2018, at 13:43, Ulf Aslak ***@***.***> wrote:
Alright, it was fast enough to try. So I upgraded with pip to v0.0.6 (right one?), but the bug is still there.
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub <#4 (comment)>, or mute the thread <https://github.com/notifications/unsubscribe-auth/AKOzvHoDsYKiQpXnOPjrzouCc05a_zq_ks5uwqdWgaJpZM4YZq9D>.
|
ah on sec |
ok i'm not being very thorough checking if I installed it right here, but downloading the repo and running |
cloning probably did not include the submodule then. Can you try
git clone --recurse-submodules git@git....
… On Nov 19, 2018, at 13:50, Ulf Aslak ***@***.***> wrote:
ok i'm not being very thorough checking if I installed it right here, but downloading the repo and running python setup.py install it installs v 0.0.7, which also imports successfully, but throws the error DistutilsFileError: cannot copy tree '/anaconda3/lib/python3.7/site-packages/netwulf-0.0.7-py3.7.egg/netwulf/js': not a directory at visualize(G)
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub <#4 (comment)>, or mute the thread <https://github.com/notifications/unsubscribe-auth/AKOzvPH9htkQ5g9OuITlX4fihVyELGjvks5uwqkbgaJpZM4YZq9D>.
|
ok, off to the to-do pile then. thanks for checking!
… On Nov 19, 2018, at 14:00, Ulf Aslak ***@***.***> wrote:
Different behavior now. I interrupt and it doesn't stop, I interrupt it again and it throws error.
<https://user-images.githubusercontent.com/6390218/48708582-461a8400-ec03-11e8-8a23-9740e34c0f4b.gif>
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub <#4 (comment)>, or mute the thread <https://github.com/notifications/unsubscribe-auth/AKOzvEnFp5qusrS7Hb_PU7X5wtmB_b0qks5uwqt7gaJpZM4YZq9D>.
|
is this fixed by now? 🤔 |
can't reproduce |
This still happens to me. It's driving me crazy. Also, connected to this, the POST back to Python feature doesn't work. I'll look into this further and we can probably close this for now but jeeeeeesus.... |
super weird ...
… On Apr 9, 2019, at 06:07, Ulf Aslak ***@***.***> wrote:
Closed #4 <#4>.
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub <#4 (comment)>, or mute the thread <https://github.com/notifications/unsubscribe-auth/AKOzvIlNBxk4S91sPKphMwKyouONfuXLks5vfIJrgaJpZM4YZq9D>.
|
It seems to everything right down to line 274 if interactive.py where it hangs on |
I reopen this ... you won't be the only one having this problem |
can you post the specific error message?
|
This is the output when hitting "Post to Python" and then upon returning to the notebook (where the kernel is still busy), interrupting the kernel:
|
I'm on Python 3.7.3, and netwulf version 0.0.14 |
can you try with the latest commit? I'm pretty sure it won't work but a guy can dream |
I like your spirit but no cigar. Also, this never runs if you don't interrupt (click Post to Python in webapp) |
Can it have something to do with the Recall that everything runs smoothly down to and including line 273: |
Yeah, I was wondering the same. It's weird though, because `self.server_close()` in line 83 should definitely stop the process.
I'll look into it again in a few days, have to prepare a talk today :/
Here are some links I found which might contain a solution. Using this comment as a bookmark:
https://stackoverflow.com/questions/3788208/threading-ignores-keyboardinterrupt-exception
https://www.oreilly.com/library/view/python-cookbook/0596001673/ch06s03.html
agronholm/pythonfutures#50
https://stackoverflow.com/questions/50891103/after-keyboardinterrupt-except-and-finally-blocks-are-not-executing
eventlet/eventlet#230
http://paste.openstack.org/show/204506/
… On Apr 9, 2019, at 06:36, Ulf Aslak ***@***.***> wrote:
Can it have something to do with the http.serve_forever() line? And that it excepts OSErrors? I tried removing the try-except clause, and nothing happened, but still as I understand it, thread.join() is ineffective because thread is still busy.
—
You are receiving this because you modified the open/close state.
Reply to this email directly, view it on GitHub <#4 (comment)>, or mute the thread <https://github.com/notifications/unsubscribe-auth/AKOzvCYk07v1wtlwvk0soSUW6TpgjjqDks5vfIkwgaJpZM4YZq9D>.
|
Cool thanks. No stress, just got hung up on this now... |
I've added a timeout to |
I now added a functionality which stops |
Sweet this works! Causes an error when doing a keyboardinterrupt in Jupyter, made a pull request that fixes this #13 . |
This is a weird one. When I
KeyboardInterrupt
in a Jupyter Notebook, a very CPU hungry Python process starts.When I restart the kernel, it terminates. If I terminate it in the activity monitor, the Jupyter kernel becomes busy (no output in terminal).
Even weirder, if I launch a new visualization, IT STOPS.
The text was updated successfully, but these errors were encountered: