-
-
Notifications
You must be signed in to change notification settings - Fork 1.7k
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
Crash while getting completions of DataFrames on the Editor because of Jedi 0.9 #2659
Comments
Thanks for reporting. Does this error happens with any DataFrame you're working on on the Editor? |
Another question: did this happen in our previous version? I mean, with 2.3.5.2? |
I did not notice this issue before and I have done quite a bit of work with pandas data frames before. |
It happens with different data sets as well. Here is an example that uses a data set from the web:
|
Thanks for the reproducible example. That would make much easier to fix this problem :-) I think it was caused by me, trying to fix issue #2514. There are other bug reports that seem to suggest the same. |
I have the same problem. It would be amazing if this could be fixed |
It's the same for me... I've also tested it with older version, but the error still occurs. |
Same for me. One example: it crashes as soon as I type "sum()" to sum up values in a pandas Dataframe column... This is really hampering my coding. |
For people suffering from this bug: |
@blink1073, this seems a problem with Jedi because Rope can't introspect DatafFrames. Could you take a look at it? |
I can't reproduce the error on master, I tried it with
|
Also worked with 2.3.5.2. |
Aha, the crash occurs when I update to Jedi 0.9, I'll investigate further. |
This is some strange interaction between the QThread and Jedi, because I printed out the function call and ran it in IPython and it comes out fine: In [1]: import jedi
In [2]: s = jedi.Script(u"import pandas\ndata = pandas.read_csv('TradeoffData.csv')\nfrom_grp = data.", 3, 16)
In [3]: s.completions()
[<Completion: abs>,
<Completion: add_prefix>,
<Completion: add_suffix>,
... The error does not occur in Python 3. I'm afraid switching to |
One more reason to get to work ;-) |
@blink1073, is there something we can about this to avoid the crash in our stable branch? This is very serious! :-) |
At least some try except so that spyder does not crash? |
Nop, it just occurred to me a simpler solution: forbid Jedi 0.9 as an accepted version, and only use 0.8.1 instead (if present) :-) |
Or that |
Yep, I'll do it for 2.3.7 ;-) |
Yeah, I think that is the only way. There is nothing to "catch" because it is a segfault. |
Once it is a separate process, it should work fine, but if it crashes, we just restart it. |
so, will Jedi >=0.9 be admitted again at a later time? Is there an issue tracking this? could this be related to davidhalter/jedi#520? |
@bilderbuchi, yes, it will be admitted again. We think this issue was generated because we are using Qt threads to get completions from both rope and jedi. For 3.0 we plan to move to use QProcess'es instead. |
Description
Crash while editing files
What steps will reproduce the problem?
What is the expected output? What do you see instead?
Please provide any additional information below
See stack trace at end.
Version and main components
Optional dependencies
The text was updated successfully, but these errors were encountered: