Intellij python no recoginiize lib
Question: I use intellij with python plugin. when I want to import python libs like
import random I got editor error. No module named random less... (Ctrl+F1)
This inspection detects names that should resolve but don't. Due to dynamic
dispatch and duck typing, this is possible in a limited but useful number of
cases. Top-level and class-level items are supported better than instance
items.

when I run the code every thing is ok what can I do to make the intelij
recognize this libs?


Answer: You may have fixed this by now, but I was having the same problem and finally
solved it, so I figured I'd post the solution for anyone who came here by
Googling/Binging the error message:

I went to File > Project Structure > Modules, highlighted the main module,
then pressed the plus sign and then "Python" under "Framework".

Hope that helps you or someone else.

