Giter Site home page Giter Site logo

sanjit-sinha / telegrambot-boilerplate Goto Github PK

View Code? Open in Web Editor NEW
104.0 4.0 41.0 734 KB

Create Telegram Bot with this friendly python boilerplate using pyrogram framework.

License: MIT License

Python 99.52% Dockerfile 0.48%
pyrogram pyrogram-bot telegram telegram-bot telegram-bot-api boilerplate boilerplate-template telegram-bot-boilerplate telegram-bot-example python

telegrambot-boilerplate's People

Contributors

ani-codes avatar imnotdev25 avatar junedkh avatar jusidama18 avatar muhammad-aadil avatar sanjit-sinha avatar sourcery-ai[bot] avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

telegrambot-boilerplate's Issues

More Decorators.

More Decorators for handling aync functions.

  • TimeOut decorator for async functions.

Server Stats and all the images related plugins isn't working

Getting this error in /serverstats

[28-Nov-23 02:40:05 - ERROR] - pyrogram.dispatcher - x1 must be greater than or equal to x0
Traceback (most recent call last):
File "/root/vip_url_bot/myenv/lib/python3.8/site-packages/pyrogram/dispatcher.py", line 240, in handler_worker
await handler.callback(self.client, *args)
File "/root/vip_url_bot/TelegramBot/helpers/decorators.py", line 45, in decorator
else: return await func(client, update)
File "/root/vip_url_bot/TelegramBot/plugins/sudo/serverstats.py", line 62, in stats
draw_progressbar(243, int(cpu_percentage))
File "/root/vip_url_bot/TelegramBot/plugins/sudo/serverstats.py", line 31, in draw_progressbar
draw.rectangle((120, coordinate, progress, coordinate-25), fill='#FFFFFF')
File "/root/vip_url_bot/myenv/lib/python3.8/site-packages/PIL/ImageDraw.py", line 301, in rectangle
self.draw.draw_rectangle(xy, fill, 1)
ValueError: x1 must be greater than or equal to x0

ToDos

  • Further improvement of ratelimit "per chat_id" instead of only ratelimit "per user_id"
  • anon users problem
  • Better Type hinting
  • Switching to filters instead of decorators

Adding more decorators for

  • running sync functions asynchronously .
  • running async function wich is time blocking asynchronously.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.