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

Internal Python Language Server error #11756

Closed
N22YF opened this issue Mar 9, 2020 · 4 comments
Closed

Internal Python Language Server error #11756

N22YF opened this issue Mar 9, 2020 · 4 comments

Comments

@N22YF
Copy link

N22YF commented Mar 9, 2020

Description

What steps will reproduce the problem?

Just editing code - didn't do anything unusual. ??

Traceback

  File "C:\Users\AlexStoll\Anaconda3\lib\site-packages\pyls_jsonrpc\endpoint.py", line 113, in consume
    self._handle_request(message['id'], message['method'], message.get('params'))
  File "C:\Users\AlexStoll\Anaconda3\lib\site-packages\pyls_jsonrpc\endpoint.py", line 182, in _handle_request
    handler_result = handler(params)
  File "C:\Users\AlexStoll\Anaconda3\lib\site-packages\pyls_jsonrpc\dispatchers.py", line 23, in handler
    return method(**(params or {}))
  File "C:\Users\AlexStoll\Anaconda3\lib\site-packages\pyls\python_ls.py", line 321, in m_text_document__completion
    return self.completions(textDocument['uri'], position)
  File "C:\Users\AlexStoll\Anaconda3\lib\site-packages\pyls\python_ls.py", line 239, in completions
    completions = self._hook('pyls_completions', doc_uri, position=position)
  File "C:\Users\AlexStoll\Anaconda3\lib\site-packages\pyls\python_ls.py", line 155, in _hook
    return hook_handlers(config=self.config, workspace=workspace, document=doc, **kwargs)
  File "C:\Users\AlexStoll\Anaconda3\lib\site-packages\pluggy\hooks.py", line 286, in __call__
    return self._hookexec(self, self.get_hookimpls(), kwargs)
  File "C:\Users\AlexStoll\Anaconda3\lib\site-packages\pluggy\manager.py", line 93, in _hookexec
    return self._inner_hookexec(hook, methods, kwargs)
  File "C:\Users\AlexStoll\Anaconda3\lib\site-packages\pluggy\manager.py", line 337, in traced_hookexec
    return outcome.get_result()
  File "C:\Users\AlexStoll\Anaconda3\lib\site-packages\pluggy\callers.py", line 80, in get_result
    raise ex[1].with_traceback(ex[2])
  File "C:\Users\AlexStoll\Anaconda3\lib\site-packages\pluggy\callers.py", line 52, in from_call
    result = func()
  File "C:\Users\AlexStoll\Anaconda3\lib\site-packages\pluggy\manager.py", line 335, in <lambda>
    outcome = _Result.from_call(lambda: oldcall(hook, hook_impls, kwargs))
  File "C:\Users\AlexStoll\Anaconda3\lib\site-packages\pluggy\manager.py", line 87, in <lambda>
    firstresult=hook.spec.opts.get("firstresult") if hook.spec else False,
  File "C:\Users\AlexStoll\Anaconda3\lib\site-packages\pluggy\callers.py", line 208, in _multicall
    return outcome.get_result()
  File "C:\Users\AlexStoll\Anaconda3\lib\site-packages\pluggy\callers.py", line 80, in get_result
    raise ex[1].with_traceback(ex[2])
  File "C:\Users\AlexStoll\Anaconda3\lib\site-packages\pluggy\callers.py", line 187, in _multicall
    res = hook_impl.function(*args)
  File "C:\Users\AlexStoll\Anaconda3\lib\site-packages\pyls\plugins\jedi_completion.py", line 68, in pyls_completions
    return [_format_completion(d, include_params) for d in definitions] or None
  File "C:\Users\AlexStoll\Anaconda3\lib\site-packages\pyls\plugins\jedi_completion.py", line 68, in <listcomp>
    return [_format_completion(d, include_params) for d in definitions] or None
  File "C:\Users\AlexStoll\Anaconda3\lib\site-packages\pyls\plugins\jedi_completion.py", line 103, in _format_completion
    if include_params and hasattr(d, 'params') and d.params:
  File "C:\Users\AlexStoll\Anaconda3\lib\site-packages\jedi\cache.py", line 143, in wrapper
    result = method(self, *args, **kwargs)
  File "C:\Users\AlexStoll\Anaconda3\lib\site-packages\jedi\api\classes.py", line 338, in params
    for context in self._name.infer():
  File "C:\Users\AlexStoll\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\AlexStoll\Anaconda3\lib\site-packages\jedi\evaluate\syntax_tree.py", line 622, in tree_name_to_contexts
    raise ValueError("Should not happen. type: %s" % typ)

ValueError: Should not happen. type: del_stmt  File "C:\Users\AlexStoll\Anaconda3\lib\site-packages\pyls_jsonrpc\endpoint.py", line 113, in consume
    self._handle_request(message['id'], message['method'], message.get('params'))
  File "C:\Users\AlexStoll\Anaconda3\lib\site-packages\pyls_jsonrpc\endpoint.py", line 182, in _handle_request
    handler_result = handler(params)
  File "C:\Users\AlexStoll\Anaconda3\lib\site-packages\pyls_jsonrpc\dispatchers.py", line 23, in handler
    return method(**(params or {}))
  File "C:\Users\AlexStoll\Anaconda3\lib\site-packages\pyls\python_ls.py", line 321, in m_text_document__completion
    return self.completions(textDocument['uri'], position)
  File "C:\Users\AlexStoll\Anaconda3\lib\site-packages\pyls\python_ls.py", line 239, in completions
    completions = self._hook('pyls_completions', doc_uri, position=position)
  File "C:\Users\AlexStoll\Anaconda3\lib\site-packages\pyls\python_ls.py", line 155, in _hook
    return hook_handlers(config=self.config, workspace=workspace, document=doc, **kwargs)
  File "C:\Users\AlexStoll\Anaconda3\lib\site-packages\pluggy\hooks.py", line 286, in __call__
    return self._hookexec(self, self.get_hookimpls(), kwargs)
  File "C:\Users\AlexStoll\Anaconda3\lib\site-packages\pluggy\manager.py", line 93, in _hookexec
    return self._inner_hookexec(hook, methods, kwargs)
  File "C:\Users\AlexStoll\Anaconda3\lib\site-packages\pluggy\manager.py", line 337, in traced_hookexec
    return outcome.get_result()
  File "C:\Users\AlexStoll\Anaconda3\lib\site-packages\pluggy\callers.py", line 80, in get_result
    raise ex[1].with_traceback(ex[2])
  File "C:\Users\AlexStoll\Anaconda3\lib\site-packages\pluggy\callers.py", line 52, in from_call
    result = func()
  File "C:\Users\AlexStoll\Anaconda3\lib\site-packages\pluggy\manager.py", line 335, in <lambda>
    outcome = _Result.from_call(lambda: oldcall(hook, hook_impls, kwargs))
  File "C:\Users\AlexStoll\Anaconda3\lib\site-packages\pluggy\manager.py", line 87, in <lambda>
    firstresult=hook.spec.opts.get("firstresult") if hook.spec else False,
  File "C:\Users\AlexStoll\Anaconda3\lib\site-packages\pluggy\callers.py", line 208, in _multicall
    return outcome.get_result()
  File "C:\Users\AlexStoll\Anaconda3\lib\site-packages\pluggy\callers.py", line 80, in get_result
    raise ex[1].with_traceback(ex[2])
  File "C:\Users\AlexStoll\Anaconda3\lib\site-packages\pluggy\callers.py", line 187, in _multicall
    res = hook_impl.function(*args)
  File "C:\Users\AlexStoll\Anaconda3\lib\site-packages\pyls\plugins\jedi_completion.py", line 68, in pyls_completions
    return [_format_completion(d, include_params) for d in definitions] or None
  File "C:\Users\AlexStoll\Anaconda3\lib\site-packages\pyls\plugins\jedi_completion.py", line 68, in <listcomp>
    return [_format_completion(d, include_params) for d in definitions] or None
  File "C:\Users\AlexStoll\Anaconda3\lib\site-packages\pyls\plugins\jedi_completion.py", line 103, in _format_completion
    if include_params and hasattr(d, 'params') and d.params:
  File "C:\Users\AlexStoll\Anaconda3\lib\site-packages\jedi\cache.py", line 143, in wrapper
    result = method(self, *args, **kwargs)
  File "C:\Users\AlexStoll\Anaconda3\lib\site-packages\jedi\api\classes.py", line 338, in params
    for context in self._name.infer():
  File "C:\Users\AlexStoll\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\AlexStoll\Anaconda3\lib\site-packages\jedi\evaluate\syntax_tree.py", line 622, in tree_name_to_contexts
    raise ValueError("Should not happen. type: %s" % typ)

ValueError: Should not happen. type: del_stm

Versions

  • Spyder version: 4.0.1
  • Python version: 3.6.8
  • Qt version: 5.9.6
  • PyQt5 version: 5.9.2
  • Operating System: Windows 10

Dependencies

atomicwrites >=1.2.0         :  1.3.0 (OK)
chardet >=2.0.0              :  3.0.4 (OK)
cloudpickle >=0.5.0          :  1.3.0 (OK)
diff_match_patch >=20181111  :  20181111 (OK)
intervaltree                 :  None (OK)
IPython >=4.0                :  7.12.0 (OK)
jedi =0.14.1                 :  0.14.1 (OK)
nbconvert >=4.0              :  5.6.1 (OK)
numpydoc >=0.6.0             :  0.9.2 (OK)
pexpect >=4.4.0              :  4.8.0 (OK)
pickleshare >=0.4            :  0.7.5 (OK)
psutil >=0.3                 :  5.6.7 (OK)
pygments >=2.0               :  2.5.2 (OK)
pylint >=0.25                :  2.4.4 (OK)
pyls >=0.31.2;<0.32.0        :  0.31.7 (OK)
zmq >=17                     :  18.1.1 (OK)
qdarkstyle >=2.7             :  2.8 (OK)
qtawesome >=0.5.7            :  0.6.1 (OK)
qtconsole >=4.6.0            :  4.6.0 (OK)
qtpy >=1.5.0                 :  1.9.0 (OK)
rtree >=0.8.3                :  0.9.3 (OK)
sphinx >=0.6.6               :  2.4.0 (OK)
spyder_kernels >=1.8.1;<2.0.0:  1.8.1 (OK)
watchdog                     :  None (OK)
cython >=0.21                :  0.29.7 (OK)
matplotlib >=2.0.0           :  3.0.3 (OK)
numpy >=1.7                  :  1.18.1 (OK)
pandas >=0.13.1              :  1.0.1 (OK)
scipy >=0.17.0               :  1.2.1 (OK)
sympy >=0.7.3                :  1.4 (OK)
@ccordoba12
Copy link
Member

What's your parso version?

@N22YF
Copy link
Author

N22YF commented Mar 10, 2020

0.6.1

@ccordoba12
Copy link
Member

Please downgrade to 0.5.2. That's the only version compatible with Jedi 0.14.1

@N22YF
Copy link
Author

N22YF commented Mar 10, 2020

Ah okay, thanks! I just installed through Anaconda - not sure why I ended up with incompatible versions.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants