Skip to content

Firyst/KPolyakovTelegramBot

Repository files navigation

KPolyakov telegram bot

This project contains a python https://kpolyakov.spb.ru/ tasks parser, a simple sql database operator and a telegram bot that can operate parsed tasks. This project is very specific and is rather for personal use.

Project structure

Scripts

cat_parser.py - This is simple script to parse task caterogies from website.
tasks_parser.py
- Main tasks parser. Before running make sure that cats.json is generated, otherwise script won't work. Should be executed only if tasks update is required.
replace_pows.js
- A script that replaces sub and sup html tags with unicode symbols as telegram doesn't yet support sup and sub tags.
sql_operator.py
- Used both with bot and parser. Contains MyTask and MyUser classes (actual db models) and has some methods to simplfy working with db.
bot.py
- Telegram bot. (aiogram)

Prepared data

cats.json - All task categories.
db.sqlite3
- Prepared database.
replies/
- Text files with large bot replies (/help, /manual).

About

Website tasks parser + telegram bot + database

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published