You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In the official documentation example for the TextInput widget in aiogram_dialog, the error handler is defined as follows:
asyncdeferror(
message: Message,
dialog_: Any,
manager: DialogManager,
error_: ValueError
):
awaitmessage.answer("Age must be a number!")
However, this appears to use incorrect parameters. According to the expected behavior for the on_error handler in the TextInput widget, the correct parameters should include:
widget instead of dialog_
data for additional context.
Proposed Solution
asyncdeferror(
message: Message,
widget: Any,
manager: DialogManager,
data: dict
):
awaitmessage.answer("Age must be a number!")
Additional Information:
This issue is based on the example provided in the documentation for the TextInput widget. If I have misunderstood how the parameters are intended to work, I would appreciate clarification.
P.S. This issue is related to documentation.
The text was updated successfully, but these errors were encountered:
Problem Description:
In the official documentation example for the
TextInput
widget inaiogram_dialog
, theerror
handler is defined as follows:However, this appears to use incorrect parameters. According to the expected behavior for the
on_error
handler in theTextInput
widget, the correct parameters should include:widget
instead ofdialog_
data
for additional context.Proposed Solution
Additional Information:
This issue is based on the example provided in the documentation for the
TextInput
widget. If I have misunderstood how the parameters are intended to work, I would appreciate clarification.P.S. This issue is related to documentation.
The text was updated successfully, but these errors were encountered: