Telegram bot will warn you about traffic jams on your route by schedule.
-
Clone repo.
-
Create python virtual environment and activete it:
python -m venv env source ./env/bin/activate
On Windows machines virtual env activates by command
env\Scripts\activate
-
Install required python modules:
pip install -r requirements.txt
-
Set required environment variables or fill in .env file.
-
Run bot:
python bot.py
- BOT_TOKEN - (str) Auth token to connect Bot to Telegram services.
- DB_FILE - (str) Sqlite database filename with relative path. Default: store/data.sqlite.
- DEBUG - (bool) Display debugging information in terminal session. Default: False.
- LOG_CONFIG - (dict) Configuring the logging module from a dictionary for
dictConfig()
function. Default: seeDEFAULT_CONFIG
in utils/log.py.
Any OS with version of Python >= 3.8. Hardware specs: 1 core CPU, 512 Mb of RAM.
- beautifulsoup4
- python-dotenv
- apscheduler
- sqlalchemy
- aiogram
- pydantic
- requests
docker-compose up -d
Use additional parameter --build
after changes the source or pull updates from repo.
-
Formatting: default is autopep8, but black allowed with
-S
param (don't format single quotes). -
Linting: before commit check your code by pylint. Config at .pylintrc file.