Spyder: Error after opening a parenthesis in the IPython console

Created on 19 Jun 2019  路  5Comments  路  Source: spyder-ide/spyder

Description

What steps will reproduce the problem?

Script:

import numpy as np

def single_angle(a):
    return a

def angles_from_R(R):
    """Get ax, ay, az from a rotation matrix."""
    ay = np.arcsin(R[0, 2])
    ax = - np.asin(R[1, 2] / np.cos(ay))
    az = - np.asin(R[0, 1] / np.cos(ay))

    return single_angle([[ax, ay, az]])

run this and then write in the console:
angles_from_R(

PS: I can't copy/paste from the editor with the issue editor open?

Traceback

  File "/usr/local/lib/python3.7/site-packages/qtconsole/base_frontend_mixin.py", line 138, in _dispatch
    handler(msg)
  File "/Users/quentinpeter/pyscripts/spyder/spyder/plugins/ipythonconsole/widgets/help.py", line 109, in _handle_inspect_reply
    documentation = self.get_documentation(content)
  File "/Users/quentinpeter/pyscripts/spyder/spyder/plugins/ipythonconsole/widgets/help.py", line 46, in get_documentation
    documentation = text.split(signature)
ValueError: empty separator

Versions

  • Spyder version: 4.0.0.dev0 d62835ff2
  • Python version: 3.7.3
  • Qt version: 5.12.3
  • PyQt5 version: 5.12.2
  • Operating System: Darwin 18.6.0

Dependencies

pygments >=2.0     :  2.3.1 (OK)
qdarkstyle >=2.6.4 :  2.6.5 (OK)
sphinx >=0.6.6     :  1.8.5 (OK)
psutil >=0.3       :  5.6.1 (OK)
pyls >=0.19.0;<0.25:  0.24.0 (OK)
nbconvert >=4.0    :  5.4.1 (OK)
pandas >=0.13.1    :  0.24.2 (OK)
numpy >=1.7        :  1.16.2 (OK)
sympy >=0.7.3      :  1.3 (OK)
cython >=0.21      :  0.29.6 (OK)
qtconsole >=4.5.0  :  4.5.1 (OK)
IPython >=4.0      :  7.3.0 (OK)
matplotlib >=2.0.0 :  3.0.3 (OK)
pylint >=0.25      :  2.3.1 (OK)
IPython Console Bug

All 5 comments

@dalthviz, please take a look at this one.

@ccordoba12 I think this was fixed by PR #9582 and I could not reproduce this with the latest master:
script
@impact27 could you do a pull to check if you're running with the latest version of Spyder? Thanks!

With the changes in PR #9585 is looking like this:
imagen

It is fixed in the latest master.

Thanks @dalthviz for taking a look at this one and @impact27 for your confirmation.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

marianux picture marianux  路  3Comments

yogu220172 picture yogu220172  路  3Comments

JesterEE picture JesterEE  路  3Comments

hedeqing picture hedeqing  路  3Comments

hgijeon picture hgijeon  路  3Comments