AlexZai007 / AnsweringMachineTelegram

nice telegram autoresponder with which it is easy to communicate
MIT License
1 stars 1 forks source link

'src' #1

Open Haipy02 opened 1 year ago

Haipy02 commented 1 year ago

C:\Users\DREAM\Desktop\AnsweringMachineTelegram-main\src>python main.py Traceback (most recent call last): File "C:\Users\DREAM\Desktop\AnsweringMachineTelegram-main\src\main.py", line 5, in from src.config import Config ModuleNotFoundError: No module named 'src'

from telethon import TelegramClient, events
from termcolor import cprint
import asyncio

from src.config import Config
from src.service import DataBase
db = DataBase(Config.db_name)

But this is not a module, what to do?

AlexZai007 commented 1 year ago

I'm sorry, I didn't test it before putting it on github. I have my environment set up in such a way that everything works. But if you run the program without an environment, then you need to remove .src from each import

from (->)

from src.config import Config
from src.service import DataBase

to (<-)

from config import Config
from service import DataBase