Solve the problem of red wavy line in the module imported from Pycharm
A red wavy line appears in the module imported by myself in Pycharm, as shown in the figure below. However, it can operate normally. The main problem is the file directory, and the module simply imported by import cannot find the path.
if you don’t feel comfortable with the red wavy line, you can also choose to solve this problem. The next two steps will be completed.
step 1:
enter Settings, go to the Python Console under the Console, check the option “Add source roots to PYTHONPAT”, and then click OK
. Step 2:
right click on the Directory and select Mark Directory as in the popup menu bar, then continue to select Sources Root, and you will immediately see the red wavy line in the code has been automatically removed.
Read More:
- How to solve the problem that the output results of C + + program written in VS2010 flash by
- solve log.info The problem of reporting error and red line
- Solve the problem of pychar import error
- Pychar has a problem downloading module [install packages failed: installing packages: error occurred. Details…]
- Unable to call numpy in pychar, module notfounderror: no module named ‘numpy’
- Error report on & written by latex in overleaf
- How to solve the import failure by prompting beautifulsoup under pychar
- The bash file written by windows runs in Linux system error
- Solve the problem of using in tensoft 2. X tf.contrib.slim No module named appears in the package: tensorflow.contrib problem
- CentOS solves the problem of modulenotfounderror when salt calls python3 script remotely, and solves the problem that PIP3 module cannot be shared by different users
- The problem of unable to install win32gui in building Anaconda environment in pychar
- Solve the problem that target code version of Maven project sub module in IntelliJ idea is always rolled back
- Solution to garbled code problem after importing project in eclipse
- Solution to the incomplete display of big data files printed by pychar
- Solve the problem of showing unregistered (unknown custom element) when importing components into Ant Design Pro
- Solve the problem of error running console reported by pycharm Python console
- Under idea struts.xml The problem of “red” in extends = “struts default”
- Java 8 Stream – Read a file line by line
- How to solve the problem that the project module turns grey in Maven
- The error of GetSet method encapsulated by idea2020 is red