Python: 'ModuleNotFoundError' when trying to import module from imported package

后端 未结 3 1223
情书的邮戳
情书的邮戳 2020-12-30 10:43

I\'m using Python 3.7.1 on macOS Mojave Version 10.14.1

This is my directory structure:

man/                          
  Mans/                  
             


        
3条回答
  •  旧时难觅i
    2020-12-30 11:31

    For me when I created a file and saved it as python file, I was getting this error during importing. I had to create a filename with the type ".py" , like filename.py and then save it as a python file. post trying to import the file worked for me.

提交回复
热议问题