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

Reservation notifications and Orders do not work consistently #393

Open
ihor-chaban opened this issue Jul 27, 2023 · 2 comments
Open

Reservation notifications and Orders do not work consistently #393

ihor-chaban opened this issue Jul 27, 2023 · 2 comments

Comments

@ihor-chaban
Copy link

ihor-chaban commented Jul 27, 2023

Several times I noticed the situation when I received the reservation notification but then my orders list was empty.

An example:
IMG_2876

When I checked the logs I saw the following error:

ERROR    Create Order Error: (200, b'{"state":"SOLD_OUT"}')

Looks like the notification is being sent when it tries to reserve the bag, not when the bag is actually reserved.

Another thing I observe in such cases - sometimes the order list is not empty, but instead, I see some other monitored bags that obviously can't be reserved at this moment.
So, I assume, when the scanner tries to reserve a bag but fails to do so, it might somehow mess up the failed reservation with others and display invalid information.

An example:
screenshot_27-07-23_14-18-32
The notification says the bag was reserved, but it's not there. Instead, I see two other orders which are definitely not reserved at the moment.

I think both issues have the same root - incorrect handling of failed reservations.
Unfortunately, debug was not enabled so I don't have relevant logs for such cases to help investigate.
Nothing else useful appears in logs with the default logging level.

@Der-Henning
Copy link
Owner

Hi @ihor-chaban.
You are totally right. The notification is sent every time the scanner tries to reserve the item, even if it is unavailable. This behavior is not intended and will be fixed in the next release.
Thank you for reporting the issue.

@ihor-chaban
Copy link
Author

Thanks @Der-Henning.

Do you know why the second issue might happen also (two other bags are listed in orders instead of the correct one)?

Der-Henning added a commit that referenced this issue Jul 28, 2023
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