Skip to content
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

ValidationError in send_photo() #133

Open
truenicoco opened this issue Jul 11, 2024 · 1 comment
Open

ValidationError in send_photo() #133

truenicoco opened this issue Jul 11, 2024 · 1 comment

Comments

@truenicoco
Copy link
Contributor

client.send_photo() has a default photo_width parameter of None, which attempts to construct a InputMessagePhoto with None as width, raising a pydantic validation error. A workaround is to pass 0. Same goes for photo_height, added_sticker_file_ids which is None when it should be an empty list.

send_video() and send_audio() have similar issues.

@pylakey
Copy link
Owner

pylakey commented Jul 14, 2024

Thanks a lot, I will have a look later

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants