-
Notifications
You must be signed in to change notification settings - Fork 103
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Bug: undefined and unspecified have different behavior #144
Comments
These values should already get stripped for JSON requests. Can you confirm that this bug only reproduces when uploading own files, and that it doesn't reproduce when sending an image by file identifier or URL? |
Can confirm. Sending images via URL works fine, this only happens via InputFile. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I migrated yet another bot to grammy and found out that there is something fishy here.
I do not use transformers or something, its so far a plain Telegraf → grammY migration.
Technically
telegraf-inline-menu
→grammy-inline-menu
is used which sets undefined to some properties instead of omitting them. I recreated the issue with plain grammY calls but haven't looked into it what exactly might cause this issue.The goal is to send a photo without caption.
Ends up creating a photo message with a caption which is literally saying "undefined".
Fails with "Call to 'sendPhoto' failed! (400: Bad Request: unsupported parse_mode)"
Part of the error contains this, which indicated the error still thinks the
undefined
isundefined
and not the string"undefined"
:I did not create a minimal bot to check these calls in a simple environment but as the bot is not that complex I dont think there are side effects to it currently. But I might be wrong here.
The text was updated successfully, but these errors were encountered: