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: Provide a warning when running autocomplete in a way that could segfault #5980

Merged
merged 1 commit into from
Aug 23, 2024

Conversation

niloc132
Copy link
Member

Simple mitigation for jedi setting the recursion limit too high for Python 3.9 and 3.10 to correctly handle RecursionErrors. This prevents a segfault for a known bug in jedi, and only applies in cases where we know the bug can take place.

Technically it is possible for these python versions to crash in this way without autocomplete or numpy, but it first would require the recursion limit to be raised, so the fix only applies when autocomplete is used.

The deephaven_internal.autocompleter module has a set_max_recursion_limit method to define a different max recursion limit for an application, in case the default of 2000 is not sufficient for all cases.

Fixes #5878
Backport #5954

…segfault (deephaven#5954)

Simple mitigation for jedi setting the recursion limit too high for
Python 3.9 and 3.10 to correctly handle RecursionErrors. This prevents a
segfault for a known bug in jedi, and only applies in cases where we
know the bug can take place.

Technically it is possible for these python versions to crash in this
way without autocomplete or numpy, but it first would require the
recursion limit to be raised, so the fix only applies when autocomplete
is used.

The `deephaven_internal.autocompleter` module has a
`set_max_recursion_limit` method to define a different max recursion
limit for an application, in case the default of 2000 is not sufficient
for all cases.

Fixes deephaven#5878
@devinrsmith devinrsmith merged commit 4581ce5 into deephaven:rc/v0.36.x Aug 23, 2024
24 checks passed
@github-actions github-actions bot locked and limited conversation to collaborators Aug 23, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants