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

Restart: Cleanup kernel process #877

Merged
merged 2 commits into from Jun 16, 2017

Conversation

lgeiger
Copy link
Member

@lgeiger lgeiger commented Jun 16, 2017

Follow up on #853

This will ensure to kill the old kernel process before starting a new one.

For me this fixes the issue describe by @t9md: #863 (comment)

Unfortunately I can't reproduce #863 so I don't know for sure if this will fix the original issue.

@lgeiger lgeiger added the bug 🐛 For unexpected issues label Jun 16, 2017
@lgeiger lgeiger force-pushed the cleanup-kernel-process branch 2 times, most recently from 8b41214 to 4e7b79c Compare June 16, 2017 19:10
@rgbkrk rgbkrk merged commit bbaaaf8 into nteract:master Jun 16, 2017
@lgeiger lgeiger deleted the cleanup-kernel-process branch June 16, 2017 20:41
@arl-o
Copy link
Contributor

arl-o commented Jun 16, 2017

#863 is still active.

@lgeiger
Copy link
Member Author

lgeiger commented Jun 16, 2017

@wowserx Just to make sure, have you tested with the latest master? v1.17.0 doesn't yet include this fix.

@arl-o
Copy link
Contributor

arl-o commented Jun 16, 2017

I feel silly, wasn't running atom in dev mode.

#863 is no longer active! It works fine.

@lgeiger
Copy link
Member Author

lgeiger commented Jun 16, 2017

Awesome thanks for checking! 🎉

I'll ship a patch release since this fixes a critical issue.

@t9md
Copy link
Contributor

t9md commented Jun 17, 2017

For me this fixes the issue describe by @t9md: #863 (comment)

I still can reproduce with latest master v1.17.1.

My steps to reproduce is

  1. prepare sample code below.
let a = [1, 2, 3]
a.push(10)
a // %%
a.push(20)
a // %%
a.push(30)
a.map(e => e * e)
a // %%
  1. execute restart-kernel-and-re-evaluate-bubbles via keymap so that I can execute multiple times with short gab between each execution.

My keymap is here,

'atom-text-editor':
  'cmd-h': 'hydrogen:restart-kernel-and-re-evaluate-bubbles'
  1. If I execute ten times(repeat cmd-h ten times while seeing result of each fire), I can see some instance where bubbles are not filled with value(checkmark which represent undefined).

restart-not-stable

@arl-o
Copy link
Contributor

arl-o commented Jun 17, 2017

I can reproduce the above, but it's not the same problem as #863, since the code is definitely running, just not consistently re-populating the bubbles.

In #863, the process was hanging indefinitely, but in the issue described above I've had it work where only some of the bubbles populate, but their results are correct:

screen shot 2017-06-17 at 08 52 52

I could also reproduce this problem by mashing a custom keymap which calls restart kernel and clear bubbles simultaneously, then quickly running the code.

@BenRussert
Copy link
Member

@t9md want to try that my fork on #876? I think this could be related to #870

@t9md
Copy link
Contributor

t9md commented Jun 19, 2017

@BenRussert Sorry for late response(I didn't noticed this comment).
I tried with #876, and but no luck, I can still reproduce this the issue I described above.
How about you?
The step is very simple, "Invoking restart-and-re-evaluate via keymap multiple times for ijavascript kernel"

@BenRussert
Copy link
Member

@t9md I see your issue now. This is a weird one.

@t9md
Copy link
Contributor

t9md commented Jun 20, 2017

So you could reproduce it right?

@lgeiger
Copy link
Member Author

lgeiger commented Jun 20, 2017

Looks like we run into #591 with IJavascript

@lgeiger
Copy link
Member Author

lgeiger commented Jun 20, 2017

@t9md Is this issue something that comes up in your normal workflow, or does it only happen when you rapidly run this command?

@t9md
Copy link
Contributor

t9md commented Jun 20, 2017

Yes, I can say it's easily happens in normal workflow.
I believe, you and all other people can easily reproduce this issue, by

  • invoke restart-kernel-and-re-evaluate-bubbles via keymap on ijavascript kernel.

This is NOT corner case of usage.
As my understanding, I didn't see this issue before hydrogen introduce rapid restart mechanism.
I prefer "slow but reliable" behavior than "quick but occasional un-reliable" behavior.
I want you and other maintainer try to reproduce this issue, and if it's really easy to reproduce as I explained, then my opinion is, we should revert to slow-but-reliable behavior worked in previous version.
I wonder if #591 is related(this is old issue), why this issue was not happened(I believe so) in previous slow restart then begin to appear from rapid restart?

@lgeiger
Copy link
Member Author

lgeiger commented Jun 20, 2017

👍 I'll take a look at it later this week.

@rgbkrk
Copy link
Member

rgbkrk commented Jun 20, 2017

we should revert to slow-but-reliable behavior worked in previous version

That sounds good to me.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug 🐛 For unexpected issues
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants