Closed grossqx closed 1 year ago
Not sure is this is relevant, but services still work. Just checked.
I have this same issue. Grocy is running normally. Error came after newest update 0.18.2. I can see this error from logs -> "Error setting up entry Grocy for grocy"
Have no issues with add-on 0.18.2 (Grocy 3.3.1) and integration 4.5.0.
@grossqx Check the due date for the tasks in Grocy, there is an invalid date somewhere. Grocy does some validation but you can bypass it.
@ainetaki Can you open a new issue and fill out the template? We need more information to help.
@marcelvriend It helped! I had some tasks in my grocy that were created from hass interface via lovelace-grocy-chores-card. Those were created a while ago,while on a previous version of both grocy and the integration. After I deleted those tasks, it immediately started working. Thank you! Hope this information helps to pinpoint where the wrong date format originated.
The issue appeared again after update of hass supervisor to 2022.08.5. Everything else is also in the latest version. Component v.4.5.2
All entities are unavailable and the log throws a:
Error fetching grocy data: Update failed: 1 validation error for CurrentChoreResponse next_estimated_execution_time invalid datetime format (type=value_error.datetime)
I tried removing the latest actions that were taken through the integration right before it broke. This time it doesn't help
Apparently there is incorrect data in your Grocy db (coming from the Android app you mentioned). Grocy and also this integration require valid data. To fix it, you need to find and correct the invalid chore(s) in Grocy.
@marcelvriend yes, you are absolutely right. But there might be also other grocy integrations or apps that cause this error because, as you have said, grocy apparently allows to bypass the validation. And even with these incorrect data, grocy itself works without any errors and displays all fields correctly. Would it be possible to ignore the errors in a particular chore or a particular product? I would expect it to show null values instead of disabling the whole integration. Or at least if there's, for example, a chore data error, would it be possible to keep stock and shopping list working? Because right now all entities go to unavailable if there's incorrect data in at least one of grocy objects. And unless you spot the problem right away and know what to look for, it is hard to pinpoint.
The linked PR will ensure that not all entities become unavailable.
Describe the bug All entities provided by the integration became unavaliable.
To Reproduce Update the Grocty addon to 0.18.2
Versions of custom component also tried with no luck: 4.3.4 4.4.0 4.5.0 (beta, currently installed)
I have also tried deleting and adding back the integration, re-enabling all entities, restarting multiple times, creating a new grocy API key.
Log: