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

onPreCheckoutQuery will not handle queries if OrderInfo contains non-nullable value only in one field #917

Open
Towich opened this issue Nov 4, 2024 · 4 comments

Comments

@Towich
Copy link

Towich commented Nov 4, 2024

I have an issue with sendInvoice and onPreCheckoutQuery

If sendInvoice have only requireEmail = true but doesn't have all of this:

requireName = true,
requirePhoneNumber = true,
requireShippingAddress = true

then onPreCheckoutQuery will not handle preCheckoutQuery.

I think It's because class OrderInfo have only non-nullable fields, so I guess fields can be nullable

Снимок экрана 2024-11-04 в 19 30 39
Copy link

github-actions bot commented Nov 4, 2024

Welcome with your first issue

InsanusMokrassar added a commit that referenced this issue Nov 11, 2024
@InsanusMokrassar InsanusMokrassar linked a pull request Nov 11, 2024 that will close this issue
@InsanusMokrassar
Copy link
Owner

Hello and thank you for your issue and full description. I will publish 20.0.1 asap (I think, this night by UTC), could you please check it and close this issue if it will be resolved?

@InsanusMokrassar InsanusMokrassar removed a link to a pull request Nov 11, 2024
@Towich
Copy link
Author

Towich commented Nov 16, 2024

I checked in 20.0.1, but this solution wasn't fix it, onPreCheckoutQuery not handle this query

Bug steps:

  1. Send invoice to user (sendInvoice() with requireEmail = true)

  2. Click on "Pay" on message:

Снимок экрана 2024-11-16 в 23 01 18
  1. Click on "Pay" in invoice:
Снимок экрана 2024-11-16 в 23 02 43
  1. Enter a password:
Снимок экрана 2024-11-16 в 23 00 22 Снимок экрана 2024-11-16 в 22 50 11
  1. After a few seconds this message appears
Снимок экрана 2024-11-16 в 22 56 30

If I don't use requireEmail = true in sendInvoice() it's works successful

@InsanusMokrassar
Copy link
Owner

Hi and thank you for answer :) could you send me (maybe in dm) logs of bot in the moment of payment? You may look how to setup advanced logger here

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