spyder: Automatic Help/Documentation with Ctrl+I is broken in the Editor
Pressing Control+I does not bring up any documentation from the Editor
What steps will reproduce the problem?
- Launch spyder
- Create a new file in the editor, type some valid code in it
- Place cursor in a method call or object name that you want to get documentation for
- Press Ctrl+I
- Be sad when nothing happens
I tried the following code in the Editor:
list()
import matplotlib.pyplot as plt
plt.figure()
Hitting Ctrl+I with my cursor in the list or plt.figure() calls didn’t bring up the documentation.
Typing list in the iPython console and hitting Ctrl+I works properly, it’s just the Editor that has the issue.
What is the expected output? What do you see instead? The Help pane should show the documentation associated with the variable that the cursor is in, such as matplotlib.pyplot.figure, in the example above.
Rather than showing the documentation, the Help pane goes blank (so we do see that some sort of action was triggered).
Please provide any additional information below I have used this feature before, but it stopped working a few point releases ago.
To test this and be sure I hadn’t screwed anything up in my setup, I created a new conda environment with spyder in it via:
conda create -n spyder-test spyder
Then I activated the new environment and launched spyder.
Version and main components
- Spyder Version: 3.2.3
- Python Version: 3.6.2
- Qt Versions: 5.6.2, PyQt5 5.6 on Windows
Dependencies
pyflakes >=0.6.0 : 1.5.0 (OK)
pycodestyle >=2.3: 2.3.1 (OK)
pygments >=2.0 : 2.2.0 (OK)
pandas >=0.13.1 : 0.20.3 (OK)
numpy >=1.7 : 1.13.1 (OK)
sphinx >=0.6.6 : 1.6.3 (OK)
rope >=0.9.4 : 0.10.5 (OK)
jedi >=0.9.0 : 0.10.2 (OK)
nbconvert >=4.0 : 5.3.1 (OK)
sympy >=0.7.3 : 1.1.1 (OK)
cython >=0.21 : 0.26.1 (OK)
qtconsole >=4.2.0: 4.3.1 (OK)
IPython >=4.0 : 6.1.0 (OK)
pylint >=0.25 : 1.7.2 (OK)
About this issue
- Original URL
- State: closed
- Created 9 years ago
- Reactions: 2
- Comments: 60 (23 by maintainers)
Resetting the keyboard shortcuts didn’t work. Deleting my ~/.spyder-py3 directory and restarting Spyder did fix the problem.
Thanks.
Potential fix. Try opening the Online Help pane (Ctrl + Shift + D). As soon as I opened it, my other help pane started working. Hopefully this helps you too. Deleting my ~/.spyder-py3 directory and restarting Spyder did not fix the problem. Nor did falling back in versions. But it could have been a combination of things.
Same problem. Sometimes it works, sometimes it doesn’t. Anaconda navigator version 1.8.3, conda 4.5.11, python 3.6, spyder 3.2.6. anaconda version 5.1.0 build py35_2
The problem could be rich text, I can see the document if I turn rich text off.
This seems to be a fix, worked for me.
To everybody following this issue:
Kite is a free plugin for several IDEs and editors that uses machine learning to provide better code completions for Python. We are planning to add support for Kite in Spyder, but before proceeding we’d like to know your opinion about it. Please help us with that by filling the following poll:
https://www.quiz-maker.com/poll2385657x93274cD6-68
Note: This doesn’t mean that if we do that integration, code completions will only work through Kite. Spyder will give the completions provided by Kite along with the ones from other open source libraries, like Jedi and Rope.
@CAM-Gerlach Thank you for your answer. I solved the issue through temporary changing
Rich TexttoPlain Textin the pane configuration right up. After itInspect objectgot working and I was able to switch back toRich Textagain at normal working. Finally it works now withRich Textproperly.@CAM-Gerlach yes I am using spyder 4, my help does not work. I have only help for numpy, the rest there is ‘No documentation Available’ I did try re-starting , I did try plain text-rich text in pane, also did try If the problem still exists, ‘go to tools -> preferences -> help tick relevant boxes under automatic connections restart python Should solve the problem’ I did try online help, not of them worked.
Strange, but glad you found a solution. Hopefully this will be mostly resolved for good in Spyder 4.
The current Spyder version is 3.3.1; 3.2.6 is nearly a year old by now. It might or might not fix the problem, but it certainly won’t hurt, and it also greatly improves your ability to select any Python environment (Anaconda or otherwise) installed on your machine to work in while keeping your dedicated Spyder environment pristine and free of the sorts of dependency issues that are nearly always the ultimat cause of this problem. You can install it into a clean environment with
conda create -n python=3 spyder,activateit, then runspyder, and then select any environment/python.exeon your machine you want to work in, so long as it hasspyder-kernelsinstalled.If you’re working in
base, try updating to a consistent anaconda version, e.g.conda install anaconda=5.3to get generally reliable versions of the relevant dependencies. Also, locking your machine or putting it to sleep can sometimes break completion/introspection/etc (which should already be fixed in Spyder 4, which use the same architecture as VSCode and Atom), so try restarting Spyder if that’s the case.