Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

PyCharm autocomplete

I'm completely new to Python and PyCharm and I cannot figure out why PyCharm doesn't auto-completes very simple cases such as:

import pickle

pickle.dum[control+space or control+shift+space results nothing here]

I have PyCharm 2.6.2 and Python 2.7.1. What's wrong?

Add:

I'm on Mac OS 10.7.3

like image 855
user1686703 Avatar asked Sep 20 '12 17:09

user1686703


People also ask

How do I enable autocomplete in PyCharm?

Go to Settings / Preferences | Editor | General | Postfix Completion and select the Enable postfix completion checkbox.

How do I turn on autocomplete in Python?

(In Python Shell window, you can use TAB key besides the key combination of 'CTRL' and 'space' to invoke the built-in auto-completion feature.) Alternatively, you can choose the "Show Completions" in the main Edit menu to achieve the same as well.

Why am I not getting suggestions in PyCharm?

You can enable this by going to settings, going to the "Build, Execution, Deployment" section and then the "Python Debugger" subsection and enabling "Collect run-time types information for code insight".


3 Answers

Can't reproduce. Make sure you have a valid Python interpreter configured for the project. Also try File | Invalidate Caches.

pickle

like image 139
CrazyCoder Avatar answered Nov 15 '22 17:11

CrazyCoder


My experience is if you turn ON the File -> Power-Save Mode, all background tasks will be stopped, including the Auto-Complete task. So you can try turning off the Power-Save Mode.

like image 29
Simon Avatar answered Nov 15 '22 15:11

Simon


You could try with a virtualenv and on it install all you project dependencies and the go to pycharm preferences/Project Interpreter and it will update your project dependencies.

Project Inspector

like image 40
César Villaseñor Avatar answered Nov 15 '22 16:11

César Villaseñor