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

Fix: KeyError: 'petName' (same animals weight problem) #91

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

Jezza34000
Copy link

Fix KeyError: 'petName' in Sensor when record["petId"] goes to "-3"
The code -3 appears when several animals have the same weight and the litter cannot identify them

@RobertD502
Copy link
Owner

Can you elaborate which litter box model you're seeing this issue on? Curious to know, as I have not seen it happen with the currently supported litter boxes....or at least no one has reported it.

@Jezza34000
Copy link
Author

Hi @RobertD502 yes of course:
I have 2 litter boxes (PuraMax & PuraMax2) and both caused the same issue.
My 2 cats weigh are : 5.1kg and 5.2kg but the litter boxes were not precise enough in the measurement so I obtained inconsistent results on the detection of the cat who was using the litter box.
So I decided to put the 2 to 5.1Kg to cancel the inconsistent detection and there appeared this famous "-3" state.

@RobertD502
Copy link
Owner

Gotcha. I'm guessing the issue is only present in the event (device record) endpoint, whereas, during that event the statistics page shows a pet ID of 0?

@Jezza34000
Copy link
Author

Good question i didn't check this

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

Successfully merging this pull request may close these issues.

2 participants