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 interrupt reply #1101

Merged
merged 5 commits into from Mar 4, 2023
Merged

Fix interrupt reply #1101

merged 5 commits into from Mar 4, 2023

Conversation

garlandz-db
Copy link
Contributor

issue: #1100 (comment)

Changes in PR

  • Added reply content properties for interrupt_request
  • send_interupt_children => send_interrupt_children renaming
  • Added test coverage to verify statuses are received

@garlandz-db
Copy link
Contributor Author

@blink1073 how do i add the label? i dont see an option

@garlandz-db garlandz-db changed the title [1100] Fix interrupt reply [1100][BUG] Fix interrupt reply Feb 28, 2023
@blink1073 blink1073 changed the title [1100][BUG] Fix interrupt reply Fix interrupt reply Mar 1, 2023
@blink1073 blink1073 added the bug label Mar 1, 2023
@blink1073
Copy link
Member

@ccordoba12 this fix breaks one of the spyder-kernels tests, but I believe it is the correct behavior.

@ccordoba12
Copy link
Member

@impact27, could you take a look at this one, please?

@impact27
Copy link
Contributor

impact27 commented Mar 4, 2023

In spyder kernel we want to be able to raise an interrupt from a thread on the main thread. This is done by
self.kernel._send_interupt_children()

I guess we just need to rename it self.kernel._send_interrupt_children() but that means we will have to change the minimum ipykernel version so this works

@blink1073
Copy link
Member

We could make this backward compatible by having _send_interupt_children warn and call _send_interrupt_children.

@ccordoba12
Copy link
Member

ccordoba12 commented Mar 4, 2023

Well, the call to _send_interupt_children() is only present in our master branch, which hasn't been released yet. So, I think it's simpler if we skip the failing test so that this PR passes. Then we can switch to the new method name and increase our minimal IPykernel supported, as @impact27 suggested.

@ccordoba12
Copy link
Member

@blink1073, our test suite should pass now thanks to PR spyder-ide/spyder-kernels#446. I went for a simpler solution: detect if the kernel has _send_interupt_children and if not use _send_interrupt_children.

@blink1073
Copy link
Member

Confirmed, thanks all! I'll make a release early next week.

@blink1073 blink1073 merged commit e46f75b into ipython:main Mar 4, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants