-
Notifications
You must be signed in to change notification settings - Fork 209
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
send_game needs chat_id by ChatId not u32 #1066
base: master
Are you sure you want to change the base?
Conversation
Thanks for the pull request, and welcome! The Rust team is excited to review your changes, and you should hear from @WaffleLapkin (or someone else) soon. Please see the contribution instructions for more information. Namely, in order to ensure the minimum review times lag, PR authors and assigned reviewers should ensure that the review label (
|
Hi! Thank you for your pull request. Our Requester trait is created by codegen, so I'm not sure that that change will be enough. I think, it worth to change the |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for noticing the mistake! We do have a dedicated ChatId
type though, so you should use that.
crates/teloxide-core/schema.ron
Outdated
@@ -4031,7 +4031,7 @@ Schema( | |||
params: [ | |||
Param( | |||
name: "chat_id", | |||
ty: u32, | |||
ty: i64, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ty: i64, | |
ty: RawTy("ChatId"), |
This will cause a compilation error because the chat_id type declared by send_game is u32, but the type of msg.chat.id is i64
and should change send_message(chat_id : u32) to send_message(chat_id : i64) to make it work
here is the issues detail #1065