Replaced error TypeError: TelegramEventObserver.__call__() got an unexpected keyword argument '<name>' with a more understandable (#1114)

* Explain why keyword filters is not supported

* Added changelog
This commit is contained in:
Alex Root Junior 2023-02-05 16:13:06 +02:00 committed by GitHub
parent d07e8fc407
commit 021ae5626f
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
4 changed files with 30 additions and 4 deletions

View file

@ -2,6 +2,7 @@ from typing import Any, Optional
from aiogram.methods import TelegramMethod
from aiogram.methods.base import TelegramType
from aiogram.utils.link import docs_url
class AiogramError(Exception):
@ -28,6 +29,10 @@ class CallbackAnswerException(AiogramError):
pass
class UnsupportedKeywordArgument(DetailedAiogramError):
url = docs_url("migration_2_to_3.html", fragment_="filtering-events")
class TelegramAPIError(DetailedAiogramError):
def __init__(
self,