Skip to main content

telepot.aio.Bot convenient subclass, featuring dataset-powered SQLite.

Project description

davtelepot

This project conveniently subclasses third party telepot.aio.Bot, providing many interesting features.

Please note that you need Python3.5+ to run async code

Check requirements.txt for third party dependencies.

Check out help(Bot) for detailed information.

Project folders

data folder

  • *.db: databases used by bots
  • *.log: log files (store log_file_name and errors_file_name in data/config.py module)
  • passwords.py: contains secret information to be git-ignored (e.g. bot tokens)
my_token = 'token_of_bot1'
my_other_token = 'token_of_bot2'
...

Usage

from davtelepot import Bot
from data.passwords import my_token, my_other_token

my_bot = Bot(token=my_token, db_name='my_db')
my_other_bot = Bot(token=my_other_token, db_name='my_other_db')

@my_bot.command('/foo')
async def foo_command(update):
  return "Bar!"

@my_other_bot.command('/bar')
async def bar_command(update):
  return "Foo!"

Bot.run()

Check out help(Bot) for detailed information.

Project details


Release history Release notifications | RSS feed

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

davtelepot-1.4.24.tar.gz (27.7 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

davtelepot-1.4.24-py3-none-any.whl (27.4 kB view details)

Uploaded Python 3

File details

Details for the file davtelepot-1.4.24.tar.gz.

File metadata

  • Download URL: davtelepot-1.4.24.tar.gz
  • Upload date:
  • Size: 27.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.12.1 pkginfo/1.4.2 requests/2.20.0 setuptools/40.4.3 requests-toolbelt/0.8.0 tqdm/4.28.1 CPython/3.6.7

File hashes

Hashes for davtelepot-1.4.24.tar.gz
Algorithm Hash digest
SHA256 8287671dcd19ba860f8c67684881a37de7ccc16060e2ab3a841a6c1c5948a9e3
MD5 b0322b7dfbd7ab0e1e3a78ec89bdc412
BLAKE2b-256 b9c0b279f18a9029ced225f303366edd6ccd3f57bf9bc7e40419151fb9d60085

See more details on using hashes here.

File details

Details for the file davtelepot-1.4.24-py3-none-any.whl.

File metadata

  • Download URL: davtelepot-1.4.24-py3-none-any.whl
  • Upload date:
  • Size: 27.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.12.1 pkginfo/1.4.2 requests/2.20.0 setuptools/40.4.3 requests-toolbelt/0.8.0 tqdm/4.28.1 CPython/3.6.7

File hashes

Hashes for davtelepot-1.4.24-py3-none-any.whl
Algorithm Hash digest
SHA256 b175810401accc226a5e29cb4bbb1e27a19f32ffa4cdf4462f725d0c69139aaa
MD5 76cde77b5187974eafe55d622b84fc2c
BLAKE2b-256 33efeff05e2c1a854f6d90f52b70ca03d83b3eb64ed3865b6e5f8c853a0a3f38

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page