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
I got a 400 Error BUTTON_DATA_INVALID when using menu plugin. The error message is very confusing and it took me a while to debug.
Turns out it's because I used long menu id and and long payload data so the callback query data exceeded Telegram's limit. (I didn't know menu id was also passed to api as part of callback query data. And even if I knew, it would be tricky for developer to keep track of bytes used for callback query data because menu plugin adds its own stuff to it).
Would be helpful if menu plugin could check payload length before making api request, and output some meaningful error message, e.g. telling me how many bytes are available for payload data.
The text was updated successfully, but these errors were encountered:
This should ideally just be a warning. I do not want to perform client-side validation because the limits may change and then the plugin would be more restrictive than necessary.
I got a
400 Error BUTTON_DATA_INVALID
when using menu plugin. The error message is very confusing and it took me a while to debug.Turns out it's because I used long menu id and and long payload data so the callback query data exceeded Telegram's limit. (I didn't know menu id was also passed to api as part of callback query data. And even if I knew, it would be tricky for developer to keep track of bytes used for callback query data because menu plugin adds its own stuff to it).
Would be helpful if menu plugin could check payload length before making api request, and output some meaningful error message, e.g. telling me how many bytes are available for payload data.
The text was updated successfully, but these errors were encountered: