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

Stellar | Check pending donation onchain on specific events #4573

Closed
MoeNick opened this issue Aug 15, 2024 · 12 comments
Closed

Stellar | Check pending donation onchain on specific events #4573

MoeNick opened this issue Aug 15, 2024 · 12 comments
Assignees
Labels

Comments

@MoeNick
Copy link
Member

MoeNick commented Aug 15, 2024

Was talking to @Meriem-BM to seek for a live solution to detect in seconds, or we run one manual fetch data before

  • we let the user click back,
  • before changing the status to failed OR when the time is up
  • before raising a ticket.
    So we make sure it's not a pending state on our side and no need to mention the 5 min @maryjaf (FYI)

Originally posted by @MoeNick in #4422 (comment)

@MoeNick
Copy link
Member Author

MoeNick commented Aug 15, 2024

FYI: @maryjaf

@Meriem-BM
Copy link
Collaborator

@maryjaf this one ready for test.

@maryjaf
Copy link
Collaborator

maryjaf commented Aug 19, 2024

@maryjaf this one ready for test.

Could you please tell me more about this new change and behavior? actually what changes was made in this page?
image

@Meriem-BM
Copy link
Collaborator

@maryjaf user might make a donation in last minutes, or scan QR code and tries to go back which will mark it as failed, and since we refresh UI every 5 mins when user is waiting for status update it might be missed, so we added fetching updated status on certain events (when time is up, when user try raising a ticket, or hen going back) to avoid any mismatch and get last status before those events.

@maryjaf
Copy link
Collaborator

maryjaf commented Aug 20, 2024

when time is up

  • 1- it seems there is a problem in this case (when time is up), as you can see in below video after the time is over this request, operationName:"GetDonationById" hasnot been called
Screen.Recording.2024-08-20.at.10.54.49.AM.mov

and after about 2 mins I see the below pic

image

@maryjaf
Copy link
Collaborator

maryjaf commented Aug 20, 2024

  • 2- one question
    When users refresh the page this request shouldn't be called? @Meriem-BM @MoeNick

@MoeNick
Copy link
Member Author

MoeNick commented Aug 20, 2024

For 2 I think we can do it while loading the page if @Meriem-BM agrees.

@maryjaf
Copy link
Collaborator

maryjaf commented Aug 20, 2024

when user try raising a ticket,

  • 3- in this case the time is over and user hasn't donated to the project, the behavior is like below record
  • after the time is over, the related request is called and the status is pending
  • when I tap on the "raise a ticket" the request is called and the status is pending

my question is that if the showing pending status in this scenario is correct when the the time is over and there is no donation?

Screen.Recording.2024-08-20.at.11.58.21.AM.mov

@maryjaf
Copy link
Collaborator

maryjaf commented Aug 22, 2024

when user try raising a ticket,

  • 3- in this case the time is over and user hasn't donated to the project, the behavior is like below record
  • after the time is over, the related request is called and the status is pending
  • when I tap on the "raise a ticket" the request is called and the status is pending

my question is that if the showing pending status in this scenario is correct when the the time is over and there is no donation?

Screen.Recording.2024-08-20.at.11.58.21.AM.mov

[ ] 1- it seems there is a problem in this case (when time is up), as you can see in below video after the time is over this request, operationName:"GetDonationById" hasnot been called

kindly reminder

@MoeNick
Copy link
Member Author

MoeNick commented Aug 22, 2024

For 3 - the status should change to failed when the time is up, A manual check on this event could only change the status to success if there's a donation is detected on-chain within the 5 min intervals. @maryjaf
For better testing please youse different amounts.
FYI: @Meriem-BM

@maryjaf
Copy link
Collaborator

maryjaf commented Aug 26, 2024

  • 3- in this case the time is over and user hasn't donated to the project, the behavior is like below record
  • after the time is over, the related request is called and the status is pending
  • when I tap on the "raise a ticket" the request is called and the status is pending

Is there an update related to this item?

@Meriem-BM
Copy link
Collaborator

when user try raising a ticket,

  • 3- in this case the time is over and user hasn't donated to the project, the behavior is like below record
  • after the time is over, the related request is called and the status is pending
  • when I tap on the "raise a ticket" the request is called and the status is pending

my question is that if the showing pending status in this scenario is correct when the the time is over and there is no donation?

Screen.Recording.2024-08-20.at.11.58.21.AM.mov

@maryjaf the cron job runs every minute to get transactions on stellar, so I make sure to not mark any donation as failed when time is up until one minute passes, to make sure if any donation detected in next minute, because the user might donation in last minute on seconds. if you wait 1 min it will be changed to failed.

@divine-comedian divine-comedian closed this as completed by moving to Merged to Production in All-Devs Oct 3, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
Status: Done
Development

No branches or pull requests

4 participants