Generate Imports While Typing

Avoid interruption by letting PyCharm generate your imports as you type.

This is the right way to do imports.

As you are typing a symbol, you have to both finish typing the symbol -- and without a typo -- and you have to import it. For the import, you have to stop what you're doing, scroll up, enter the import in the correctly-sorted PEP8 way, etc.

Let PyCharm do all of that. While typing, press ⌃␣ (macOS) / Ctrl+Space (Windows/Linux) to tell PyCharm to autocomplete on symbols from modules. When you select the completion target, PyCharm will also generate the import -- in the right place, merging it with an existing import if needed.


Related Resources

Clean Up Messy Imports With Optimize Imports
Clean Up Messy Imports With Optimize Imports
Quickly remove any unused imports and more.
Find in Path with the Navigation Bar
Find in Path with the Navigation Bar
Use the Navigation bar and Find in File together and be faster than all of your team members.
Speed search with the Navigation Bar
Speed search with the Navigation Bar
Use the keyboard abbreviations to quickly find what you're looking for in the Navigation bar.