After working for a while in Spyder at some point several functions just stop working:
Often there is no error message, sometimes there is one that tells me that code completion and linting will not work in the current session or have stopped working. It tells me to make sure that my firewall or antivirus allow Python processes to open ports on my system or to restart Spyder.
I'm working at a company behind a company firewall with an Antivirus Software.
My question is now:
EDIT 1:
I played around with the advanced settings. In the end I enabled the usage of STDIO-Pipes and started Spyder with that option enabled. Performance was worse and the error also happened after a while, so I switched the option off and continued working. Apparently this restarted the language server and since then (about an hour ago) it has been running without fail. This makes it look more like the issue is not with my system's firewall or antivirus but some internal Spyder issue, maybe something that happens at startup?
EDIT 2:
After about 4 hours the error happend again. I did what I did above, go into the settings, activate STDIO-Pipes, then deactivate it again, now the server is running again normally.
cloudpickle >=0.5.0 : 1.2.2 (OK)
pygments >=2.0 : 2.5.2 (OK)
qtconsole >=4.6.0 : 4.6.0 (OK)
nbconvert >=4.0 : 5.6.1 (OK)
sphinx >=0.6.6 : 2.2.2 (OK)
pylint >=0.25 : 2.4.4 (OK)
psutil >=0.3 : 5.6.7 (OK)
qtawesome >=0.5.7 : 0.6.0 (OK)
qtpy >=1.5.0 : 1.9.0 (OK)
pickleshare >=0.4 : 0.7.5 (OK)
zmq >=17 : 18.1.1 (OK)
chardet >=2.0.0 : 3.0.4 (OK)
numpydoc >=0.6.0 : 0.9.1 (OK)
spyder_kernels >=1.8.1;<2.0.0: 1.8.1 (OK)
qdarkstyle >=2.7 : 2.7 (OK)
atomicwrites >=1.2.0 : 1.3.0 (OK)
diff_match_patch >=20181111 : 20181111 (OK)
intervaltree : None (OK)
watchdog : None (OK)
keyring : None (OK)
pexpect >=4.4.0 : 4.7.0 (OK)
pympler : None (OK)
sympy >=0.7.3 : 1.4 (OK)
cython >=0.21 : 0.29.14 (OK)
IPython >=4.0 : 7.10.1 (OK)
matplotlib >=2.0.0 : 3.1.2 (OK)
pandas >=0.13.1 : 0.25.3 (OK)
numpy >=1.7 : 1.17.3 (OK)
scipy >=0.17.0 : 1.3.1 (OK)
pyls >=0.31.2;<0.32.0 : 0.31.2 (OK)
rtree >=0.8.3 : 0.9.1 (OK)
I have been using Spyder normally today for about 3 hours now. The error didn't reappear and I didn't have to rely on that workaround I described above so far.
Sadly I have no clue what caused that error as it appeared rather randomly, I can't reproduce it. It's possible that switching from working with one file to another makes it more probable to occur, but that's speculation now.
I think this is caused by the server crashing at some point in the background. Therefore, I'll add a menu entry so that users can manually restart the server in case that happens.
@Khris777, that's equivalent to the workaround you mentioned and it'll be available in our next version.
I am using Spyder 4.0 (conda install) and all autocomplete and code navigation "crashes" all the time. Although I see no error, it just stops working. I found a nice way to reproduce it in my code, but not as a snippet. My code is a python file which includes many packages and has functions in it. This is tested inside one of the functions. But as Spyder crashes all the time, I guess this is not specific to my large project:
After closing Spyder and launching again all is fine. I suspect that the the issue might be related with parsing a larger project + fast user actions. I have noticed that I've also been hitting Esc to suppress some completion and typed myself fast. So perhaps it just crashes when not being able to handle typing speed combined with complex code and possible syntax errors. As I said, doing exactly the same thing in a vanilla python file does not crash Spyder. If there is a way to log what happens, I am happy to reproduce and log :)
Edit: my system is Python 3.6.9 on Ubuntu 18.04
@martinrebane, please post an animated gif of the situation you described above because I don't understand it very well.
@ccordoba12 Yes, I made a screencast. While recording I saw that it is even more simple than that. Now I got it crashed just be producing syntax error while typing.
Here is the screen recording: https://youtu.be/GY_1hR5l8rc
print
statement. I am also hitting ctrl+space there, nothing happens.Please let me know if I can help any further!
Just in case, here are my settings for code completion:
While I had crashes last week, since monday I didn't have a single crash or problem anymore.
No idea why it's gone now.
I have the same problem constantly. Mine does not go away. Only fix is to restart Spyder.
Same problem here as described in OP. I also have the same problem that @martinrebane describes, except I'm not working on any large/complex projects.
Restarting Spyder fixes the issue for a short while. Sometimes its only minutes before the issue is back. Have tried resetting Spyder. I have not been able to see anything in logs/internal console - but I'd be happy to assist more if I can.
Spyder 4.0.0
Python 3.7.5 64-bit | Qt 5.12.5 | PyQt5 5.12.3 | Windows 10
Just to add another - linter gets "stuck" thinking a variable is never used, even after it is, and even after its definition is commented entirely (which should yield a red marker): lint_demo.mp4 (_note_: using UTF-8 encoding)
Circumventable by cutting out a few lines above and below the offending one, and pasting back
Version 4.0.1, but still happens to me too - seemingly every single time I use Spyder. No idea how to produce it on purpose, other than just coding away for a while. Only fix I have found so far is to restart Spyder.
I saw issue #11501 and #11500 which I guess are the same as this issue or at least related.
Running Spyder with "--debug-info verbose" I get a different error (EOFError vs. ValueError) than #11501. Also with this level of debug enabled it appears the language server restarts. So code completion, linting, go to definition etc keeps working but continues to crash repeatedly when trying to code-complete. Same behavior with and without Kite enabled.
Running Spyder without debug it seems the language server just crashes and doesn't restart, as is described in the rest of this thread.
Edit: Spyder 4.0.1
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\cache.py", line 42, in wrapper
rv = function(obj, *args, **kwargs)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\context\function.py", line 311, in get_executed_params_and_issues
return self.var_args.get_executed_params_and_issues(self)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\context\instance.py", line 530, in get_executed_params_and_issues
return self._wrapped_arguments.get_executed_params_and_issues(execution_context)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\context\instance.py", line 54, in get_executed_params_and_issues
execution_context.tree_node
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\debug.py", line 82, in wrapper
return func(*args, **kwargs)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\dynamic.py", line 98, in search_params
string_name=string_name,
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\cache.py", line 42, in wrapper
rv = function(obj, *args, **kwargs)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\utils.py", line 20, in wrapper
return list(func(*args, **kwargs))
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\dynamic.py", line 147, in _search_function_executions
evaluator, random_context, compare_node, name, trailer):
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\dynamic.py", line 202, in _check_name_for_execution
for value in evaluator.goto_definitions(context, name):
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\__init__.py", line 280, in goto_definitions
return helpers.evaluate_call_of_leaf(context, name)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\helpers.py", line 102, in evaluate_call_of_leaf
values = context.eval_node(base)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\base_context.py", line 81, in eval_node
return self.evaluator.eval_element(self, node)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\__init__.py", line 233, in eval_element
return self._eval_element_if_evaluated(context, element)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\__init__.py", line 245, in _eval_element_if_evaluated
return self._eval_element_cached(context, element)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\cache.py", line 42, in wrapper
rv = function(obj, *args, **kwargs)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\__init__.py", line 249, in _eval_element_cached
return eval_node(context, element)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\debug.py", line 82, in wrapper
return func(*args, **kwargs)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\syntax_tree.py", line 50, in wrapper
return func(context, *args, **kwargs)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\syntax_tree.py", line 74, in eval_node
return eval_atom(context, element)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\syntax_tree.py", line 203, in eval_atom
search_global=True
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\base_context.py", line 72, in py__getattribute__
return f.find(filters, attribute_lookup=not search_global)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\finder.py", line 67, in find
types = self._names_to_types(names, attribute_lookup)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\finder.py", line 190, in _names_to_types
contexts = ContextSet.from_sets(name.infer() for name in names)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\common\context.py", line 32, in from_sets
for set_ in sets:
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\finder.py", line 190, in <genexpr>
contexts = ContextSet.from_sets(name.infer() for name in names)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\names.py", line 226, in infer
return self.get_param().infer()
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\names.py", line 229, in get_param
params, _ = self.parent_context.get_executed_params_and_issues()
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\cache.py", line 42, in wrapper
rv = function(obj, *args, **kwargs)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\context\function.py", line 311, in get_executed_params_and_issues
return self.var_args.get_executed_params_and_issues(self)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\context\instance.py", line 530, in get_executed_params_and_issues
return self._wrapped_arguments.get_executed_params_and_issues(execution_context)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\context\instance.py", line 54, in get_executed_params_and_issues
execution_context.tree_node
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\debug.py", line 82, in wrapper
return func(*args, **kwargs)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\dynamic.py", line 98, in search_params
string_name=string_name,
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\cache.py", line 42, in wrapper
rv = function(obj, *args, **kwargs)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\utils.py", line 20, in wrapper
return list(func(*args, **kwargs))
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\dynamic.py", line 147, in _search_function_executions
evaluator, random_context, compare_node, name, trailer):
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\dynamic.py", line 202, in _check_name_for_execution
for value in evaluator.goto_definitions(context, name):
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\__init__.py", line 280, in goto_definitions
return helpers.evaluate_call_of_leaf(context, name)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\helpers.py", line 105, in evaluate_call_of_leaf
values = eval_trailer(context, values, trailer)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\syntax_tree.py", line 167, in eval_trailer
name_or_str=node
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\base_context.py", line 406, in py__getattribute__
return ContextSet.from_sets(c.py__getattribute__(*args, **kwargs) for c in self._set)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\common\context.py", line 32, in from_sets
for set_ in sets:
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\base_context.py", line 406, in <genexpr>
return ContextSet.from_sets(c.py__getattribute__(*args, **kwargs) for c in self._set)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\base_context.py", line 72, in py__getattribute__
return f.find(filters, attribute_lookup=not search_global)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\finder.py", line 67, in find
types = self._names_to_types(names, attribute_lookup)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\finder.py", line 190, in _names_to_types
contexts = ContextSet.from_sets(name.infer() for name in names)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\common\context.py", line 32, in from_sets
for set_ in sets:
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\finder.py", line 190, in <genexpr>
contexts = ContextSet.from_sets(name.infer() for name in names)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\names.py", line 143, in infer
return tree_name_to_contexts(parent.evaluator, parent, self.tree_name)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\syntax_tree.py", line 604, in tree_name_to_contexts
types = _remove_statements(evaluator, context, node, tree_name)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\syntax_tree.py", line 544, in _remove_statements
return eval_expr_stmt(context, stmt, seek_name=name)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\syntax_tree.py", line 50, in wrapper
return func(context, *args, **kwargs)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\syntax_tree.py", line 287, in eval_expr_stmt
return _eval_expr_stmt(context, stmt, seek_name)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\debug.py", line 82, in wrapper
return func(*args, **kwargs)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\syntax_tree.py", line 303, in _eval_expr_stmt
context_set = context.eval_node(rhs)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\base_context.py", line 81, in eval_node
return self.evaluator.eval_element(self, node)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\__init__.py", line 233, in eval_element
return self._eval_element_if_evaluated(context, element)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\__init__.py", line 245, in _eval_element_if_evaluated
return self._eval_element_cached(context, element)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\cache.py", line 42, in wrapper
rv = function(obj, *args, **kwargs)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\__init__.py", line 249, in _eval_element_cached
return eval_node(context, element)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\debug.py", line 82, in wrapper
return func(*args, **kwargs)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\syntax_tree.py", line 50, in wrapper
return func(context, *args, **kwargs)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\syntax_tree.py", line 87, in eval_node
context_set = context.eval_node(first_child)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\base_context.py", line 81, in eval_node
return self.evaluator.eval_element(self, node)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\__init__.py", line 233, in eval_element
return self._eval_element_if_evaluated(context, element)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\__init__.py", line 245, in _eval_element_if_evaluated
return self._eval_element_cached(context, element)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\cache.py", line 42, in wrapper
rv = function(obj, *args, **kwargs)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\__init__.py", line 249, in _eval_element_cached
return eval_node(context, element)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\debug.py", line 82, in wrapper
return func(*args, **kwargs)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\syntax_tree.py", line 50, in wrapper
return func(context, *args, **kwargs)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\syntax_tree.py", line 74, in eval_node
return eval_atom(context, element)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\syntax_tree.py", line 203, in eval_atom
search_global=True
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\base_context.py", line 72, in py__getattribute__
return f.find(filters, attribute_lookup=not search_global)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\finder.py", line 67, in find
types = self._names_to_types(names, attribute_lookup)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\finder.py", line 190, in _names_to_types
contexts = ContextSet.from_sets(name.infer() for name in names)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\common\context.py", line 32, in from_sets
for set_ in sets:
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\finder.py", line 190, in <genexpr>
contexts = ContextSet.from_sets(name.infer() for name in names)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\names.py", line 226, in infer
return self.get_param().infer()
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\names.py", line 229, in get_param
params, _ = self.parent_context.get_executed_params_and_issues()
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\cache.py", line 42, in wrapper
rv = function(obj, *args, **kwargs)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\context\function.py", line 311, in get_executed_params_and_issues
return self.var_args.get_executed_params_and_issues(self)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\context\instance.py", line 530, in get_executed_params_and_issues
return self._wrapped_arguments.get_executed_params_and_issues(execution_context)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\context\instance.py", line 54, in get_executed_params_and_issues
execution_context.tree_node
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\debug.py", line 82, in wrapper
return func(*args, **kwargs)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\dynamic.py", line 98, in search_params
string_name=string_name,
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\cache.py", line 42, in wrapper
rv = function(obj, *args, **kwargs)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\utils.py", line 20, in wrapper
return list(func(*args, **kwargs))
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\dynamic.py", line 147, in _search_function_executions
evaluator, random_context, compare_node, name, trailer):
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\dynamic.py", line 202, in _check_name_for_execution
for value in evaluator.goto_definitions(context, name):
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\__init__.py", line 280, in goto_definitions
return helpers.evaluate_call_of_leaf(context, name)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\helpers.py", line 102, in evaluate_call_of_leaf
values = context.eval_node(base)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\base_context.py", line 81, in eval_node
return self.evaluator.eval_element(self, node)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\__init__.py", line 233, in eval_element
return self._eval_element_if_evaluated(context, element)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\__init__.py", line 245, in _eval_element_if_evaluated
return self._eval_element_cached(context, element)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\cache.py", line 42, in wrapper
rv = function(obj, *args, **kwargs)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\__init__.py", line 249, in _eval_element_cached
return eval_node(context, element)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\debug.py", line 82, in wrapper
return func(*args, **kwargs)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\syntax_tree.py", line 50, in wrapper
return func(context, *args, **kwargs)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\syntax_tree.py", line 74, in eval_node
return eval_atom(context, element)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\syntax_tree.py", line 203, in eval_atom
search_global=True
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\base_context.py", line 72, in py__getattribute__
return f.find(filters, attribute_lookup=not search_global)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\finder.py", line 67, in find
types = self._names_to_types(names, attribute_lookup)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\finder.py", line 190, in _names_to_types
contexts = ContextSet.from_sets(name.infer() for name in names)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\common\context.py", line 32, in from_sets
for set_ in sets:
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\finder.py", line 190, in <genexpr>
contexts = ContextSet.from_sets(name.infer() for name in names)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\names.py", line 226, in infer
return self.get_param().infer()
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\names.py", line 229, in get_param
params, _ = self.parent_context.get_executed_params_and_issues()
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\cache.py", line 42, in wrapper
rv = function(obj, *args, **kwargs)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\context\function.py", line 311, in get_executed_params_and_issues
return self.var_args.get_executed_params_and_issues(self)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\context\instance.py", line 530, in get_executed_params_and_issues
return self._wrapped_arguments.get_executed_params_and_issues(execution_context)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\context\instance.py", line 54, in get_executed_params_and_issues
execution_context.tree_node
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\debug.py", line 82, in wrapper
return func(*args, **kwargs)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\dynamic.py", line 98, in search_params
string_name=string_name,
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\cache.py", line 42, in wrapper
rv = function(obj, *args, **kwargs)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\utils.py", line 20, in wrapper
return list(func(*args, **kwargs))
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\dynamic.py", line 147, in _search_function_executions
evaluator, random_context, compare_node, name, trailer):
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\dynamic.py", line 202, in _check_name_for_execution
for value in evaluator.goto_definitions(context, name):
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\__init__.py", line 280, in goto_definitions
return helpers.evaluate_call_of_leaf(context, name)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\helpers.py", line 105, in evaluate_call_of_leaf
values = eval_trailer(context, values, trailer)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\syntax_tree.py", line 167, in eval_trailer
name_or_str=node
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\base_context.py", line 406, in py__getattribute__
return ContextSet.from_sets(c.py__getattribute__(*args, **kwargs) for c in self._set)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\common\context.py", line 32, in from_sets
for set_ in sets:
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\base_context.py", line 406, in <genexpr>
return ContextSet.from_sets(c.py__getattribute__(*args, **kwargs) for c in self._set)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\base_context.py", line 72, in py__getattribute__
return f.find(filters, attribute_lookup=not search_global)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\finder.py", line 56, in find
names = self.filter_name(filters)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\finder.py", line 152, in filter_name
for filter in filters:
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\finder.py", line 122, in _get_context_filters
for f in self._context.get_filters(False, self._position, origin_scope=origin_scope):
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\context\module.py", line 102, in get_filters
for star_filter in self.iter_star_filters():
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\context\module.py", line 140, in iter_star_filters
for star_module in self.star_imports():
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\cache.py", line 42, in wrapper
rv = function(obj, *args, **kwargs)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\context\module.py", line 162, in star_imports
modules += module.star_imports()
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\cache.py", line 42, in wrapper
rv = function(obj, *args, **kwargs)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\context\module.py", line 157, in star_imports
level=i.level
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\imports.py", line 296, in follow
) for parent_module_context in context_set
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\imports.py", line 296, in <listcomp>
) for parent_module_context in context_set
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\__init__.py", line 139, in import_module
sys_path, prefer_stubs=prefer_stubs)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\plugins\flask.py", line 24, in wrapper
return callback(evaluator, import_names, module_context, *args, **kwargs)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\gradual\typeshed.py", line 110, in wrapper
for p in parent_module_contexts
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\common\context.py", line 32, in from_sets
for set_ in sets:
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\gradual\typeshed.py", line 110, in <genexpr>
for p in parent_module_contexts
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\imports.py", line 436, in import_module
is_package=is_pkg,
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\imports.py", line 457, in _load_python_module
cache_path=settings.cache_directory
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\__init__.py", line 454, in parse
return self.parse_and_get_code(*args, **kwargs)[0]
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jedi\evaluate\__init__.py", line 451, in parse_and_get_code
return grammar.parse(code=code, path=path, file_io=file_io, **kwargs), code
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\parso\grammar.py", line 78, in parse
return self._parse(code=code, **kwargs)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\parso\grammar.py", line 105, in _parse
module_node = load_module(self._hashed, file_io, cache_path=cache_path)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\parso\cache.py", line 98, in load_module
cache_path=cache_path
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\parso\cache.py", line 119, in _load_from_file_system
module_cache_item = pickle.load(f)
EOFError: Ran out of input
@rhkarls, please open the Anaconda prompt and run there
conda install parso=0.5.2
That should fix your problem.
@rhkarls, please open the Anaconda prompt and run there
conda install parso=0.5.2
That should fix your problem.
Cheers @ccordoba12 ! I was already running with parso 0.5.2. I tried upgrading to 0.6, and I got the same ValueError as reported in #11501. I downgraded again to 0.5.2 and it appears to work now - at least it doesn't crash straight away. A lot of other packages were also down/upgraded in the process by conda, including jedi, the language server and spyder+kernels.
Glad to hear it was solved!
To note, I verified time and again that the more the total lines of code in all files opened, the sooner the linter's functionality degrades - worst-case, immediately
@OverLordGoldDragon, please don't start to comment in unrelated issues about your errors. Thanks!
@ccordoba12 How's it unrelated? It's about linter not working after a while, just as the linked issue - I'm just adding information to a more active thread.
Sorry, I thought you were posting on a different issue.
Hi @ccordoba12
I have a similar problem. I updated to spyder 4 and now the right-click "Go to definition" doesn't work anymore. I have windows 10 and Anaconda environment. I also tried putting my project directory in the PYTHONPATH manager and it still doesn't work. Is there a solution for this issue? My project files are big and not having this feature is making it impossible to work. Any help would be greatly appreciated. Do I need to uninstall and re-install spyder 4?
I tried the solution mentioned above but it seems that parso is already installed for me. See below. How do I check the version of parso installed? And can I simply conda uninstall parso
and then again conda install parso=0.5.2
? Thanks for your help!
```conda install parso=0.5.2
Collecting package metadata (current_repodata.json): done
Solving environment: done
I tried the solution mentioned above but it seems that parso is already installed for me. See below. How do I check the version of parso installed? And can I simply
conda uninstall parso
and then againconda install parso=0.5.2
?
conda list parso
to see the version, or in a python console import parso
followed by parso.__version__
Try the commands you suggested. What worked for me, for some unexplained reason, was to install parso 0.6.0 and then downgrade to 0.5.2.
@rhkarls Thanks for the tips. I checked my parso version and indeed it was 0.5.2. So I tried to upgrade it first. So I ran conda update parso
. And in the prompt it said that it would automatically downgrade spyder to 3.3.6. I accepted it and it works now. Today morning I had done conda update --all
to fix some issues with pyTorch and torchvision installs. And didn;t realize that spyder got updated to 4.0.1.
Strangely enough, parso was upgraded to 0.6.1 and spyder to 3.3.6...automatically without even me forcing it so. But now with the downgrade of the spyder it all works. I'll keep it that way until perhaps the issues with spyder 4.0.1 are resolved. Thanks again for your timely response!! Much appreciated.
just upgraded to spyder 4.1.1, windows 10 64b
it crashes every hour or so with this "completion and linting in the editor for python files will not work ", suspect it is due to the integration with kite
suspect it is due to the integration with kite
No, it's not.
I'm also experiencing this issue. It's quite annoying as I have to run specific parts of my code again each time I restart, to load the example data I need to continue coding.
I have tried all the above solutions and none of them have worked so far. It just keeps crashing whenever I use Spyder 4.
Is there any update/solution in sight?
I am still getting spyder crashes every hour or so due to this problem, I did what @matheger suggested and started spyder in debug mode spyder --debug-info verbose:
now I get this on the issue reporter
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\star_args.py", line 188, in process_params
)), star_count=2):
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\utils.py", line 20, in wrapper
return list(func(args, *kwargs))
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\star_args.py", line 187, in process_params
signature.get_param_names(resolve_stars=False)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\star_args.py", line 79, in _remove_given_params
for key, _ in arguments.unpack():
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\arguments.py", line 212, in unpack
arrays = self.context.infer_node(el)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\context.py", line 210, in infer_node
return infer_node(self, node)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\syntax_tree.py", line 148, in infer_node
return _infer_node_if_inferred(context, element)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\syntax_tree.py", line 161, in _infer_node_if_inferred
return _infer_node_cached(context, element)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\cache.py", line 42, in wrapper
rv = function(obj, args, *kwargs)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\syntax_tree.py", line 166, in _infer_node_cached
return _infer_node(context, element)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\debug.py", line 82, in wrapper
return func(args, *kwargs)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\syntax_tree.py", line 62, in wrapper
return func(context, args, *kwargs)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\syntax_tree.py", line 176, in _infer_node
return infer_atom(context, element)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\syntax_tree.py", line 301, in infer_atom
return context.py__getattribute__(atom, position=position)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\context.py", line 75, in py__getattribute__
values = ValueSet.from_sets(name.infer() for name in names)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\common\value.py", line 32, in from_sets
for set_ in sets:
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\context.py", line 75, in
values = ValueSet.from_sets(name.infer() for name in names)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\names.py", line 237, in infer
self.tree_name
File "D:Anaconda3\envs\py37\lib\site-packages\jediplugins__init__.py", line 21, in wrapper
return built_functionsname
File "D:Anaconda3\envs\py37\lib\site-packages\jediplugins\stdlib.py", line 827, in wrapper
return func(inference_state, context, tree_name)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\syntax_tree.py", line 726, in tree_name_to_values
types = _remove_statements(context, node, tree_name)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\syntax_tree.py", line 661, in _remove_statements
return infer_expr_stmt(context, stmt, seek_name=name)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\syntax_tree.py", line 62, in wrapper
return func(context, args, *kwargs)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\syntax_tree.py", line 370, in infer_expr_stmt
return _infer_expr_stmt(context, stmt, seek_name)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\debug.py", line 82, in wrapper
return func(args, *kwargs)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\syntax_tree.py", line 402, in _infer_expr_stmt
value_set = context.infer_node(rhs)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\context.py", line 210, in infer_node
return infer_node(self, node)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\syntax_tree.py", line 148, in infer_node
return _infer_node_if_inferred(context, element)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\syntax_tree.py", line 161, in _infer_node_if_inferred
return _infer_node_cached(context, element)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\cache.py", line 42, in wrapper
rv = function(obj, args, *kwargs)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\syntax_tree.py", line 166, in _infer_node_cached
return _infer_node(context, element)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\debug.py", line 82, in wrapper
return func(args, *kwargs)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\syntax_tree.py", line 62, in wrapper
return func(context, args, *kwargs)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\syntax_tree.py", line 189, in _infer_node
value_set = context.infer_node(first_child)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\context.py", line 210, in infer_node
return infer_node(self, node)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\syntax_tree.py", line 148, in infer_node
return _infer_node_if_inferred(context, element)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\syntax_tree.py", line 161, in _infer_node_if_inferred
return _infer_node_cached(context, element)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\cache.py", line 42, in wrapper
rv = function(obj, args, *kwargs)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\syntax_tree.py", line 166, in _infer_node_cached
return _infer_node(context, element)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\debug.py", line 82, in wrapper
return func(args, *kwargs)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\syntax_tree.py", line 62, in wrapper
return func(context, args, *kwargs)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\syntax_tree.py", line 176, in _infer_node
return infer_atom(context, element)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\syntax_tree.py", line 301, in infer_atom
return context.py__getattribute__(atom, position=position)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\context.py", line 75, in py__getattribute__
values = ValueSet.from_sets(name.infer() for name in names)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\common\value.py", line 32, in from_sets
for set_ in sets:
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\context.py", line 75, in
values = ValueSet.from_sets(name.infer() for name in names)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\names.py", line 237, in infer
self.tree_name
File "D:Anaconda3\envs\py37\lib\site-packages\jediplugins__init__.py", line 21, in wrapper
return built_functionsname
File "D:Anaconda3\envs\py37\lib\site-packages\jediplugins\stdlib.py", line 827, in wrapper
return func(inference_state, context, tree_name)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\syntax_tree.py", line 719, in tree_name_to_values
cn.infer(),
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\base_value.py", line 330, in infer
return self.context.infer_node(self.node)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\context.py", line 210, in infer_node
return infer_node(self, node)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\syntax_tree.py", line 148, in infer_node
return _infer_node_if_inferred(context, element)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\syntax_tree.py", line 161, in _infer_node_if_inferred
return _infer_node_cached(context, element)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\cache.py", line 42, in wrapper
rv = function(obj, args, *kwargs)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\syntax_tree.py", line 166, in _infer_node_cached
return _infer_node(context, element)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\debug.py", line 82, in wrapper
return func(args, *kwargs)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\syntax_tree.py", line 62, in wrapper
return func(context, args, *kwargs)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\syntax_tree.py", line 200, in _infer_node
value_set = infer_trailer(context, value_set, trailer)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\syntax_tree.py", line 267, in infer_trailer
name_or_str=node
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\base_value.py", line 385, in py__getattribute__
return ValueSet.from_sets(c.py__getattribute__(args, *kwargs) for c in self._set)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\common\value.py", line 32, in from_sets
for set_ in sets:
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\base_value.py", line 385, in
return ValueSet.from_sets(c.py__getattribute__(args, *kwargs) for c in self._set)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\base_value.py", line 88, in py__getattribute__
names = self.goto(name_or_str, name_context, analysis_errors)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\base_value.py", line 77, in goto
names = finder.filter_name(filters, name_or_str)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\finder.py", line 36, in filter_name
for filter in filters:
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\base_value.py", line 63, in _get_value_filters
for f in self.get_filters(origin_scope=origin_scope):
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\filters.py", line 339, in get_filters
yield SpecialMethodFilter(self, self.overwritten_methods, self._wrapped_value)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\utils.py", line 75, in wrapper
return func(args, *kwds)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\cache.py", line 143, in wrapper
result = method(self, args, *kwargs)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\base_value.py", line 295, in _wrapped_value
return self._get_wrapped_value()
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\value\iterable.py", line 202, in _get_wrapped_value
TupleGenericManager(self._get_generics())
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\value\iterable.py", line 194, in _get_generics
return (self.merge_types_of_iterate().py__class__(),)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\base_value.py", line 58, in merge_types_of_iterate
for lazy_value in self.iterate(contextualized_node, is_async)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\common\value.py", line 32, in from_sets
for set_ in sets:
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\base_value.py", line 57, in
lazy_value.infer()
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\value\iterable.py", line 261, in py__iter__
for keys, values in self._iterate():
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\cache.py", line 42, in wrapper
rv = function(obj, args, *kwargs)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\utils.py", line 20, in wrapper
return list(func(args, *kwargs))
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\value\iterable.py", line 170, in _iterate
for result in self._nested(comp_fors):
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\value\iterable.py", line 142, in _nested
input_types = parent_context.infer_node(input_node)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\context.py", line 210, in infer_node
return infer_node(self, node)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\syntax_tree.py", line 148, in infer_node
return _infer_node_if_inferred(context, element)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\syntax_tree.py", line 161, in _infer_node_if_inferred
return _infer_node_cached(context, element)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\cache.py", line 42, in wrapper
rv = function(obj, args, *kwargs)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\syntax_tree.py", line 166, in _infer_node_cached
return _infer_node(context, element)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\debug.py", line 82, in wrapper
return func(args, *kwargs)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\syntax_tree.py", line 62, in wrapper
return func(context, args, *kwargs)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\syntax_tree.py", line 176, in _infer_node
return infer_atom(context, element)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\syntax_tree.py", line 301, in infer_atom
return context.py__getattribute__(atom, position=position)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\context.py", line 43, in py__getattribute__
names = self.goto(name_or_str, position)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\context.py", line 32, in goto
names = finder.filter_name(filters, name_or_str)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\finder.py", line 37, in filter_name
names = filter.get(string_name)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\filters.py", line 83, in get
*filter_kwargs
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\filters.py", line 122, in _filter
return list(self._check_flows(names))
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\filters.py", line 137, in _check_flows
origin_scope=self._origin_scope
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\flow_analysis.py", line 78, in reachability_check
return _break_check(context, value_scope, first_flow_scope, node)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\flow_analysis.py", line 86, in _break_check
reachable = _check_if(context, check_node)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\flow_analysis.py", line 113, in _check_if
types = context.infer_node(node)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\context.py", line 210, in infer_node
return infer_node(self, node)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\syntax_tree.py", line 148, in infer_node
return _infer_node_if_inferred(context, element)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\syntax_tree.py", line 161, in _infer_node_if_inferred
return _infer_node_cached(context, element)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\cache.py", line 42, in wrapper
rv = function(obj, *args, *kwargs)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\syntax_tree.py", line 166, in _infer_node_cached
return _infer_node(context, element)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\debug.py", line 82, in wrapper
return func(args, *kwargs)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\syntax_tree.py", line 62, in wrapper
return func(context, args, *kwargs)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\syntax_tree.py", line 200, in _infer_node
value_set = infer_trailer(context, value_set, trailer)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\syntax_tree.py", line 267, in infer_trailer
name_or_str=node
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\base_value.py", line 385, in py__getattribute__
return ValueSet.from_sets(c.py__getattribute__(args, *kwargs) for c in self._set)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\common\value.py", line 32, in from_sets
for set_ in sets:
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\base_value.py", line 385, in
return ValueSet.from_sets(c.py__getattribute__(args, *kwargs) for c in self._set)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\base_value.py", line 88, in py__getattribute__
names = self.goto(name_or_str, name_context, analysis_errors)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\base_value.py", line 77, in goto
names = finder.filter_name(filters, name_or_str)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\finder.py", line 36, in filter_name
for filter in filters:
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\base_value.py", line 63, in _get_value_filters
for f in self.get_filters(origin_scope=origin_scope):
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\filters.py", line 339, in get_filters
yield SpecialMethodFilter(self, self.overwritten_methods, self._wrapped_value)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\utils.py", line 78, in wrapper
reraise(UncaughtAttributeError(exc_info[1]), exc_info[2])
File "D:Anaconda3\envs\py37\lib\site-packages\jedi_compatibility.py", line 298, in reraise
raise exception.with_traceback(traceback)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\utils.py", line 75, in wrapper
return func(args, *kwds)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\cache.py", line 143, in wrapper
result = method(self, args, *kwargs)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\base_value.py", line 295, in _wrapped_value
return self._get_wrapped_value()
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\value\iterable.py", line 202, in _get_wrapped_value
TupleGenericManager(self._get_generics())
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\value\iterable.py", line 183, in _get_generics
return tuple(c_set.py__class__() for c_set in self.get_mapping_item_values())
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\value\iterable.py", line 560, in get_mapping_item_values
return self._dict_keys(), self._dict_values()
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\value\iterable.py", line 554, in _dict_values
return ValueSet.from_sets(lazy_value.infer() for lazy_value in self._dct.values())
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\common\value.py", line 32, in from_sets
for set_ in sets:
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\value\iterable.py", line 554, in
return ValueSet.from_sets(lazy_value.infer() for lazy_value in self._dct.values())
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\lazy_value.py", line 46, in infer
return self.context.infer_node(self.data)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\context.py", line 210, in infer_node
return infer_node(self, node)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\syntax_tree.py", line 148, in infer_node
return _infer_node_if_inferred(context, element)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\syntax_tree.py", line 161, in _infer_node_if_inferred
return _infer_node_cached(context, element)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\cache.py", line 42, in wrapper
rv = function(obj, args, *kwargs)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\syntax_tree.py", line 166, in _infer_node_cached
return _infer_node(context, element)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\debug.py", line 82, in wrapper
return func(args, *kwargs)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\syntax_tree.py", line 62, in wrapper
return func(context, args, *kwargs)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\syntax_tree.py", line 176, in _infer_node
return infer_atom(context, element)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\syntax_tree.py", line 301, in infer_atom
return context.py__getattribute__(atom, position=position)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\context.py", line 75, in py__getattribute__
values = ValueSet.from_sets(name.infer() for name in names)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\common\value.py", line 32, in from_sets
for set_ in sets:
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\context.py", line 75, in
values = ValueSet.from_sets(name.infer() for name in names)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\names.py", line 446, in infer
values = dynamic_param_lookup(self.function_value, param.position_index)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\debug.py", line 82, in wrapper
return func(args, *kwargs)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\dynamic_params.py", line 47, in wrapper
return func(function_value, param_index)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\dynamic_params.py", line 92, in dynamic_param_lookup
arguments_list = _search_function_arguments(module_context, funcdef, string_name)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\cache.py", line 42, in wrapper
rv = function(obj, args, *kwargs)
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\utils.py", line 20, in wrapper
return list(func(args, *kwargs))
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\dynamic_params.py", line 132, in _search_function_arguments
inference_state, random_context, compare_node, name, trailer):
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\dynamic_params.py", line 198, in _check_name_for_execution
param_names = value.parent_context.get_param_names()
File "D:Anaconda3\envs\py37\lib\site-packages\jedi\inference\value\instance.py", line 65, in get_param_names
self._function_value,
jedi.inference.utils.UncaughtAttributeError: 'AnonymousMethodExecutionContext' object has no attribute '_function_value'
I am still getting spyder crashes every hour or so due to this problem
Is that a hard crash (i.e. Spyder closes immediately)? Or does Spyder show the "Completion and linting stop working" message and open the issue reporter?
Try running Spyder with
--debug-info verbose
. It will nag you with crash report windows instead of just rolling over and dying.If you also add
--debug-output file
, it will create a log file somewhere in your personal folder. Might be useful for tracking this further.
Thank you. But how exactly do I do that?
Thank you. But how exactly do I do that?
I've edited my post above with a howto. Hope it helps!
@ccordoba12
Is that a hard crash (i.e. Spyder closes immediately)? Or does Spyder show the "Completion and linting stop working" message and open the issue reporter?
if I am not in debug mode, I get the error and every time I try to write something the message pops up again , so I have to shutdown spyder and restart
if I am on debug mode the error report pops up and I can close it and continue
I also have this issue since upgrading to Spyder 4.1.1
Unluckily I cannot reproduce the error by doing something specific. It just happens after around 10 to 20 minutes of coding.
I hope this gets resolved.
This is getting a little intolerable that I have to restart spyder after hours of coding.
We are working on this to improve the current UI and also add the possibility of restarting the language server manually. The new release should be available next week.
Adding to all of this, apart from often simply stopping to work without notice, sometimes it stops with that error message, and it will then spam the error message on every single keystroke.
Just saving my file provokes the error message to appear twice, so it becomes impossible to work and only a restart helps.
We are working on this to improve the current UI and also add the possibility of restarting the language server manually. The new release should be available next week.
Thanks for your efforts in sorting this out. The new linting and completion mechanisms will definitely be a step up when working properly. In the meantime is it possible to implement an option to use the old linter in Spyder 4 so that we can benefit from the other great features? I've found that linting fails after just a couple of minutes with just one relatively small file open. It sounds like the fixes you're working on won't solve the root problem and manually restarting the language server isn't going to be viable if it falls over every couple of minutes. I think if people can use the old linter it gives you more time to figure out all the issues.
Also thanks from my side!
Is there any quick fix for this? When coding heavily, this error appears more frequently than every 20 minutes. Having to clear the cache/variables etc. by restarting every few minutes totally kills my efficiency at work.
Is there any quick fix or a workaround by completely killing the linting? Otherwise I'll have to switch to PyCharm, which I'd like to avoid.
I just realized that my solution to start Spyder in debug mode fixed a different problem - that of random Spyder crashes - but not the one in the OP. I mistook one for the other because I never had the exact error message about linting/code completion and didn't read the description carefully enough. Today is the first time I ever saw it in person. I deleted my post above to not lead future readers astray.
The fix has been made and a new version coming next week. Thanks for the help debugging and your patience.
The fix has been made and a new version coming next week. Thanks for the help debugging and your patience.
Thanks a lot @goanpeca and @ccordoba12 !
To those interested in our solution, we've done the following to improve this annoying situation:
Add an option to never show the intrusive message again.
Add a mechanism that tries to detect if the server went down and tries to automatically restart it.
Add a new entry to the status bar that shows the status of the server (starting, ready, restarting or down) and a menu entry that allows to restart it manually:
While those features may help, they seem to be only remedial to recover from the aftermath of the error. Do you have any idea yet why it happens in the first place?
While those features may help, they seem to be only remedial to recover from the aftermath of the error
Hopefully things will go unnoticed from now on when the server stops working for most users, because it'll be restarted by Spyder automatically.
Do you have any idea yet why it happens in the first place?
We're still investigating the issue.
Fair enough. Fingers crossed! Looking forward to the next update.
regarding the fix for next week that automatically restarts the server: what happens to the workspace ? the variables that are in memory? will these values be lost?
Hope not, since that would mean restarting work every hour or so
regarding the fix for next week that automatically restarts the server: what happens to the workspace ? the variables that are in memory? will these values be lost?
Hope not, since that would mean restarting work every hour or so
I suspect not. There is a workaround (going into preferences, completion and linting, advanced, select 'use stdio pipes', apply, deselect use stdio pipes' again and apply) which effectively does the same (restarting the server), which has always worked for me so far and does not do anything to the workspace, variables, etc.
what happens to the workspace ? the variables that are in memory? will these values be lost?
@ricmarchao, the restart is done in place, so you don't need to restart Spyder and lose your work.
To those interested in our solution, we've done the following to improve this annoying situation:
- Add an option to never show the intrusive message again.
- Add a mechanism that tries to detect if the server went down and tries to automatically restart it.
- Add a new entry to the status bar that shows the status of the server (starting, ready, restarting or down) and a menu entry that allows to restart it manually:
How to get that option?
It'll be available in our 4.1.2 version, to be released in a couple of days.
Glad to know that and thanks for your effort.
While those features may help, they seem to be only remedial to recover from the aftermath of the error
Hopefully things will go unnoticed from now on when the server stops working for most users, because it'll be restarted by Spyder automatically.
Do you have any idea yet why it happens in the first place?
We're still investigating the issue.
Thanks for doing this. As a user though I do feel Spyder is getting quite slow and slightly delayed to work with, even with just typing code for example. Responsiveness in the program is really important and these kind of constant checks and workarounds can impact reliability of the program. Though I love Spyder, I am seriously close to changing IDE's as a result of the constant interruptions with this error, crashes and instability. Hope a true fix rather than workaround can be found?
Even getting a dialog every 20 minutes is extremely annoying when you are trying to focus. At least the variable memory will not be erased due to program crash.
Happy to help with anything.
Cheers
Peter
While those features may help, they seem to be only remedial to recover from the aftermath of the error
Hopefully things will go unnoticed from now on when the server stops working for most users, because it'll be restarted by Spyder automatically.
Do you have any idea yet why it happens in the first place?
We're still investigating the issue.
Thanks for doing this. As a user though I do feel Spyder is getting quite slow and slightly delayed to work with, even with just typing code for example. Responsiveness in the program is really important and these kind of constant checks and workarounds can impact reliability of the program. Though I love Spyder, I am seriously close to changing IDE's as a result of the constant interruptions with this error, crashes and instability. Hope a true fix rather than workaround can be found?
Even getting a dialog every 20 minutes is extremely annoying when you are trying to focus. At least the variable memory will not be erased due to program crash.
Happy to help with anything.
Cheers
Peter
Same here. It was really nice to work with Spyder 2 and 3. Features might not have been complete and/or perfect, but Spyder was working nicely without crashing and/or slowing down. Code completition was not really functional at that time, but honestly: If you are used to coding, code completition will save you only a small amount of time (compared to the cost of slow-downs or crashes).
Starting with version 4 (or perhaps already somewhere at version 3), with each new version Spyder started to introduce more bugs than features. Imho the focus should for now should be on fixing all the bugs introduced by new (highly optional) features like Kite etc...
Over the last year in my workplace Spyder "acquired" a set of nicknames, of which "Cryder" (Crashy-Spyder) is one of the most favorable. Spyder went from being the most used Python IDE to a share of about 10%. PyCharm (and some others) have taken over. Unluckily I also had to move to PyCharm yesterday, since no changes seem to happen on this critical issues and otherwise my timeschedule would break my neck...
So imho to discourage people from changing to other IDEs, fixing bugs should be top priority over new features or improving features. And this also includes bug-handling procedures. F.i. the PR on this absolutely critical bug is marked as merged since almost 5 days, but no release has been made. But isn't fixing a critical bug the best reason _ever_ to push an intermediate release, disregarding all planned PRs for the next release cycle?
While those features may help, they seem to be only remedial to recover from the aftermath of the error
Hopefully things will go unnoticed from now on when the server stops working for most users, because it'll be restarted by Spyder automatically.
Do you have any idea yet why it happens in the first place?
We're still investigating the issue.
Thanks for doing this. As a user though I do feel Spyder is getting quite slow and slightly delayed to work with, even with just typing code for example. Responsiveness in the program is really important and these kind of constant checks and workarounds can impact reliability of the program. Though I love Spyder, I am seriously close to changing IDE's as a result of the constant interruptions with this error, crashes and instability. Hope a true fix rather than workaround can be found?
Even getting a dialog every 20 minutes is extremely annoying when you are trying to focus. At least the variable memory will not be erased due to program crash.
Happy to help with anything.
Cheers
PeterSame here. It was really nice to work with Spyder 2 and 3. Features might not have been complete and/or perfect, but Spyder was working nicely without crashing and/or slowing down. Code completition was not really functional at that time, but honestly: If you are used to coding, code completition will save you only a small amount of time (compared to the cost of slow-downs or crashes).
Starting with version 4 (or perhaps already somewhere at version 3), with each new version Spyder started to introduce more bugs than features. Imho the focus should for now should be on fixing all the bugs introduced by new (highly optional) features like Kite etc...
Over the last year in my workplace Spyder "acquired" a set of nicknames, of which "Cryder" (Crashy-Spyder) is one of the most favorable. Spyder went from being the most used Python IDE to a share of about 10%. PyCharm (and some others) have taken over. Unluckily I also had to move to PyCharm yesterday, since no changes seem to happen on this critical issues and otherwise my timeschedule would break my neck...So imho to discourage people from changing to other IDEs, fixing bugs should be top priority over new features or improving features. And this also includes bug-handling procedures. F.i. the PR on this absolutely critical bug is marked as merged since almost 5 days, but no release has been made. But isn't fixing a critical bug the best reason _ever_ to push an intermediate release, disregarding all planned PRs for the next release cycle?
Agree 100%.
Has this issue been opened as a separate issue to fully investigate and fix, or is the hacky dialog box really closing the issue?
To those interested in our solution, we've done the following to improve this annoying situation:
- Add an option to never show the intrusive message again.
- Add a mechanism that tries to detect if the server went down and tries to automatically restart it.
- Add a new entry to the status bar that shows the status of the server (starting, ready, restarting or down) and a menu entry that allows to restart it manually:
How to get that option?
Ok thanks - it鈥檚 good the box can be disabled. At the moment, when one types even a single key (In the Non fixed version) the error message box comes up again and again. in the fix, if one disabled the box, can we be sure the program will not be constantly polling the external service?
Cheers
It's also worth noting that this error often occurs when one holds down backspace or deletes a lot of information in quick succession.
Same here. It was really nice to work with Spyder 2 and 3. ...
Starting with version 4 (or perhaps already somewhere at version 3), with each new version Spyder started to introduce more bugs than features. Imho the focus should for now should be on fixing all the bugs introduced by new (highly optional) features like Kite etc...
Please note that there were a _lot_ of users wanting improved code completion and other new features. The Spyder 4 release was a massive overhaul of the code base. When you do such a large release with a relatively small team, naturally bugs will creep in. The Spyder team has worked very hard over the past couple of months on bug fixing to stabilize the 4.x series. 4.1.2
was tagged yesterday, and is now a PR on conda-forge that passes all CI - so should be available shortly.
Over the last year in my workplace Spyder "acquired" a set of nicknames, of which "Cryder" (Crashy-Spyder) is one of the most favorable. Spyder went from being the most used Python IDE to a share of about 10%. PyCharm (and some others) have taken over. Unluckily I also had to move to PyCharm yesterday, since no changes seem to happen on this critical issues and otherwise my timeschedule would break my neck...
So imho to discourage people from changing to other IDEs, fixing bugs should be top priority over new features or improving features. And this also includes bug-handling procedures. F.i. the PR on this absolutely critical bug is marked as merged since almost 5 days, but no release has been made. But isn't fixing a critical bug the best reason _ever_ to push an intermediate release, disregarding all planned PRs for the next release cycle?
@JoElfner honestly, I don't think you understand what it takes to do a release of a package like Spyder. Speaking from experience as NumPy and SciPy release manager: it easily takes 1-2 days, and Spyder has a much more complex set of dependencies than NumPy/SciPy. @ccordoba12 and his team are working on this as hard as they can.
Please understand that comments like yours can be very demotivating, and are not really helpful. Community open source projects rely on a small number of maintainers, most of which are working very hard next to a day job or degree. If you want to help, please keep bug reports and comments constructive at a minimum. Contributing fixes or documentation, or donating (https://opencollective.com/spyder - $6500 yearly budget currently) would also be great to consider.
Agree 100%.
Please see my comment above @pbower
Has this issue been opened as a separate issue to fully investigate and fix, or is the hacky dialog box really closing the issue?
As @ccordoba12 said, the team is still investigating. The crashes are not in Spyder itself, so the current set of fixes (not just the dialog box, also auto-restarting) plus helping improve upstream projects seems like the right approach.
Agree 100%.
Please see my comment above @pbower
Has this issue been opened as a separate issue to fully investigate and fix, or is the hacky dialog box really closing the issue?
As @ccordoba12 said, the team is still investigating. The crashes are not in Spyder itself, so the current set of fixes (not just the dialog box, also auto-restarting) plus helping improve upstream projects seems like the right approach.
Thanks, appreciate your comments and the hard work from the team. The issue caused my spyder instance to crash 20-30 times in the last 3 days for a project, so good that it鈥檚 being investigated and fixed.
I would love help out any way possible, I鈥檓 probably not experienced enough yet though.
You guys should be proud of the work that鈥檚 been done - the plotting stuff it does is brilliant now.
Cheers
I would love help out any way possible, I鈥檓 probably not experienced enough yet though.
Thanks for your offer @pbower. What we need is a simple, reproducible use case that generates this kind of errors, so we can debug them in our side.
So if you could give us a small, self-contained sample of your code that does that, we'd be really grateful.
You guys should be proud of the work that鈥檚 been done - the plotting stuff it does is brilliant now.
Thanks for your kind words @pbower!
Looking forward to all your efforts resolving this :)
I would love help out any way possible, I鈥檓 probably not experienced enough yet though.
Thanks for your offer @pbower. What we need is a simple, reproducible use case that generates this kind of errors, so we can debug them in our side.
So if you could give us a small, self-contained sample of your code that does that, we'd be really grateful.
You guys should be proud of the work that鈥檚 been done - the plotting stuff it does is brilliant now.
Thanks for your kind words @pbower!
Thanks for that.
To replicate this error, I suggest the following:
Alternatively, code for 20-30 minutes and it will appear, crashing the program.
Python 3.7.6 | Qt 5.12.5 | PyQt 5.12.3 | Windows 10
Cheers
Peter
Same here. It was really nice to work with Spyder 2 and 3. ...
Starting with version 4 (or perhaps already somewhere at version 3), with each new version Spyder started to introduce more bugs than features. Imho the focus should for now should be on fixing all the bugs introduced by new (highly optional) features like Kite etc...Please note that there were a _lot_ of users wanting improved code completion and other new features. The Spyder 4 release was a massive overhaul of the code base. When you do such a large release with a relatively small team, naturally bugs will creep in. The Spyder team has worked very hard over the past couple of months on bug fixing to stabilize the 4.x series.
4.1.2
was tagged yesterday, and is now a PR on conda-forge that passes all CI - so should be available shortly.
Yep, I've taken note of it. I'm not saying that these features should not have been integrated, I'm just saying that a step-by-step integration could have been helpful with avoiding to introduce bugs. F.i. imho _either_ ramping up the internal code completition feature _or_ integrating things like Kite (which for example also doesn't work correctly on my machines). But not both at the same time.
Over the last year in my workplace Spyder "acquired" a set of nicknames, of which "Cryder" (Crashy-Spyder) is one of the most favorable. Spyder went from being the most used Python IDE to a share of about 10%. PyCharm (and some others) have taken over. Unluckily I also had to move to PyCharm yesterday, since no changes seem to happen on this critical issues and otherwise my timeschedule would break my neck...
So imho to discourage people from changing to other IDEs, fixing bugs should be top priority over new features or improving features. And this also includes bug-handling procedures. F.i. the PR on this absolutely critical bug is marked as merged since almost 5 days, but no release has been made. But isn't fixing a critical bug the best reason _ever_ to push an intermediate release, disregarding all planned PRs for the next release cycle?@JoElfner honestly, I don't think you understand what it takes to do a release of a package like Spyder. Speaking from experience as NumPy and SciPy release manager: it easily takes 1-2 days, and Spyder has a much more complex set of dependencies than NumPy/SciPy. @ccordoba12 and his team are working on this as hard as they can.
Please understand that comments like yours can be very demotivating, and are not really helpful. Community open source projects rely on a small number of maintainers, most of which are working very hard next to a day job or degree. If you want to help, please keep bug reports and comments constructive at a minimum. Contributing fixes or documentation, or donating (https://opencollective.com/spyder - $6500 yearly budget currently) would also be great to consider.
True and sorry for that! I have to admit that I only contributed to and/or released internal/private packages of smaller size than Spyder etc, thus I am short on experience with large packages.
My criticism does not mean that I do not ackowledge the work of the Spyder team. If I wasn't appreciating the work, I wouldn't even care to write a comment here.
In contrast: I really ackowledge the hard and great work and want to thank the team for it. I just thought that some first-hand information/user-experience pointing out some (non-coding-)issues from the user-side might be helpful. Perhaps my words were a bit harsh and/or demotivating, but I personally prefer getting direct feedback over users silently migrating to other tools.
Thanks for your offer @pbower. What we need is a simple, reproducible use case that generates this kind of errors, so we can debug them in our side.
I've only experienced these faults on a Win10 installation with Spyder installed in it's own environment. In MacOS I've not had a problem.
Anecdotally, I'd say the error arises when modifying code quickly. It doesn't necessarily matter how long the code is, or how long the program has been open. Is running Spyder in debug mode likely to prove fruitful?
Hi I have the same problem. It seems that happens randomly.
I have to say that after waiting for version 4.1, that fixed the freezing bug, now we have this. The joy of open source software is here :)
I propose professional users should switch to another environment for the times been.
Hi I have the same problem. It seems that happens randomly.
Both conda-forge and PyPI have 4.1.2 since 2 days; can you please try if this still happens with that version?
Hi I have the same problem. It seems that happens randomly.
Both conda-forge and PyPI have 4.1.2 since 2 days; can you please try if this still happens with that version?
Ok yes I will try today.
Hi,
Please re-open this issue request for 4.1.2
I have been testing today and though the dialog box disappears, once it has occurred once the program constantly freezes for 3-5 seconds until it is shut down and restarted.
Usually, after re-establishing the connection in the background, this continues frequently.
Thanks
Hi I have the same problem. It seems that happens randomly.
Both conda-forge and PyPI have 4.1.2 since 2 days; can you please try if this still happens with that version?
Hi,
Also in addition to comments above, I should add that the temporary fix is still an improvement to the original, as one does not lose their variables / work and there is an opportunity to save/pickle them before restart.
Regards,
Peter
@pbower, please open a new issue about the new problem.
I just upgraded Spyder and so far it seems to be working well. At some point I realised something was going on in the backend as my editor was very slow to react. This took about 5 seconds. It was triggered by moving through commented text in the editor by keyboard arrows, which has previously triggered the endless error popups. So I suspect this was the server restart referred to above. After 5 seconds I was able to continue working normally.
Thank you very much!
Updated Spyder and it's still occurring, usually after an hour or two of work.
@Hagbeard, you can restart the server manually if that occurs. That's all we can do at the moment.
Thanks @ccordoba12, I find killing Spyder to be most effective because the notifications come in such quick succession that even getting a ctrl+s in before the next notification can be hard.
I find killing Spyder to be most effective because the notifications come in such quick succession that even getting a ctrl+s in before the next notification can be hard.
That was in 4.1.1. We're talking about 4.1.2 (please read the last 10 or 15 messages for context).
Roger that, sorry, had previously updated to 4.1.1. It's working better now on 4.1.2, it lags when I think it's going to crash, but doesn't result in the same message and is more stable.
Great to know @Hagbeard!
I have just updated to Spyder 4.1.4 via conda (I also tried conda remove and then reinstalling). I never saw the popup about code completion and linting before, but now I get it constantly within a minute or two of launching Spyder. As the error doesn't seem to be fixed for me, anything else I should try?
@shllybkwrm, you probably have installation issues. Please open a new issue about your problem, so we can take a look at them.
Will do. In the meantime I rolled back to 4.1.3 (following a recommendation earlier in the thread,
Most helpful comment
We are working on this to improve the current UI and also add the possibility of restarting the language server manually. The new release should be available next week.