ModuleNotFoundError或这种语言有什么问题

时间:2017-04-03 15:11:41

标签: python python-3.x

这是我的简单项目。当我尝试运行app.py时出现错误:

Traceback (most recent call last):
  File "worker/app.py", line 4, in <module>
    from worker import app_config
ModuleNotFoundError: No module named 'worker'

enter image description here

以下是app.py的内容

import logging
from logging import config

from worker import app_config
from worker import controller

config.dictConfig(app_config.LOGGING)
log = logging.getLogger(__name__)


def start():
    log.info("Worker started")
    controller.update_whats_new()
    log.info("Worker exit")


if __name__ == "__main__":
    start()

init .py为空,PYTHONPATH env也为空

0 个答案:

没有答案