Closed Zapzatron closed 9 months ago
Tried telebot.logger.setLevel(logging.CRITICAL + 1)
, but it just stopped doing logging, but it won't let me handle the error myself.
Set to debug to get full information.
I have my own exception handler and I catch and handle errors in it. telebot.async_telebot.ExceptionHandler
is sometimes called and sometimes not.
you can't handle connection errors with exception handler afaik
2024-02-08 17:17:14,295 (asyncio_helper.py:101 MainThread) ERROR - TeleBot: "Aiohttp ClientError: ClientConnectorError"
This error is raised when doing requests to Telegram. In two cases:
Note, that it is re-raised as asyncio_helper.RequestTimeout exception, not Aiohttp ClientError. And the error logging will be done anyway.
What should I do to make the telebot stop handling errors? Because the telebot gives little information about the error. I need to be able to handle the error myself. I have
class ExceptionHandler(telebot.async_telebot.ExceptionHandler):
, but it doesn't always receive the error.Example of small error information from telebot: 2024-02-08 17:17:14,295 (asyncio_helper.py:101 MainThread) ERROR - TeleBot: "Aiohttp ClientError: ClientConnectorError"