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

Fix iteration over the sessions in /reconnectsparkmagic #660

Open
wants to merge 6 commits into
base: master
Choose a base branch
from

Conversation

qlemaire22
Copy link

Hi!

I noticed that the /reconnectsparkmagic endpoint was broken (with sparkmagic 0.15.0, iPython 7.16.1 and notebook 6.0.3).
I did an investigation and I found out that it was always recreating a new kernel because it could not correctly iterate over the different sessions to find to right kernel to restart.

So here is a small fix I made to make it work.

@qlemaire22
Copy link
Author

It seems to break the CI, I will do some further investigation to understand why.

@qlemaire22
Copy link
Author

qlemaire22 commented Jul 28, 2020

The test is fixed. I had to create a new function _get_list_sessions that I mocked since I didn't find a way to correctly mock session_manager.list_sessions() with the new return format (source).

If you have a solution for mocking session_manager.list_sessions(), tell me :)

@devstein
Copy link
Collaborator

devstein commented Jun 5, 2021

Hi @qlemaire22 thanks for making a PR! Is this fix still relevant? Can you provide instructions for reproducing the bug without this fix?

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

Successfully merging this pull request may close these issues.

None yet

2 participants