Grocy - Custom component and card(s)

Apologies my question was linked in the reply, have linked here too (5 posts up with my error logs)

Weā€™re all here just to help can you reply with everything you have what you use and what you have installed. Were just here to help for free need some help from your end thanks.

Yeah of course, sorry Iā€™m a bit confused as already made a post in response to Isballaā€™s questions which had the error logs from with Home Assistant (using the Grocy installation with custom component through HACS) but Iā€™ve pasted them again here:

2021-06-08 14:06:14 ERROR (MainThread) [custom_components.grocy] Update of Expired_products failed with Expecting value: line 1 column 1 (char 0)
2021-06-08 14:06:14 ERROR (MainThread) [custom_components.grocy] Update of Expiring_products failed with Expecting value: line 1 column 1 (char 0)
2021-06-08 14:06:14 ERROR (MainThread) [custom_components.grocy] Update of Missing_products failed with Expecting value: line 1 column 1 (char 0)
2021-06-08 14:06:14 ERROR (MainThread) [custom_components.grocy] Update of Overdue_chores failed with Expecting value: line 1 column 1 (char 0)
2021-06-08 14:06:14 ERROR (MainThread) [custom_components.grocy] Update of Overdue_tasks failed with Expecting value: line 1 column 1 (char 0)
2021-06-08 14:06:14 ERROR (MainThread) [custom_components.grocy] Update of Chores failed with Expecting value: line 1 column 1 (char 0)
2021-06-08 14:06:14 ERROR (MainThread) [custom_components.grocy] Update of Meal_plan failed with Expecting value: line 1 column 1 (char 0)
2021-06-08 14:06:14 ERROR (MainThread) [custom_components.grocy] Update of Shopping_list failed with Expecting value: line 1 column 1 (char 0)
2021-06-08 14:06:14 ERROR (MainThread) [custom_components.grocy] Update of Stock failed with Expecting value: line 1 column 1 (char 0)
2021-06-08 14:06:14 ERROR (MainThread) [custom_components.grocy] Update of Tasks failed with Expecting value: line 1 column 1 (char 0)

Thatā€™s the logs and whatā€™s not working. How did you setup gontho the set-up what you did. Was it working before. Need more info then just logs

Sure - Sorry Isabella said to post the logs.

I installed Grocy from Supervisor and added some generic entries so I had data. I then followed the steps for the custom component, adding the URL per the HA instance and adding my api key which stated it was successful.

However the added binary and ā€œnormalā€ sensors all had a status of ā€œunknownā€ instead of pulling data from Grocy (e.g. I knew one of my products was expired so should have been pulled through on that sensor but still said unknown).

The above logs are from my HA logs, the specific logs for Grocy had different errors which I shared above.

Redo the steps for the custom component,.you must of don something worng there

Hi All,
Iā€™m currently using Grocy to manage chores. What Iā€™d like to do is be able to push notify users when they have chores due today. Is this something that anyone can help with? I donā€™t know where to begin with parsing the current sensor, maybe even the Grocy component could add a sensor along the lines of ā€˜UserIDsWithChoresDueTodayā€™?
Thanks in advance!

I also had the problem that the tracking of my chores was registered at the wrong time. In my case, it was because the Grocy add-on was set to the wrong time zone (UTC).

Discovered this here: http://homeassistant.local:9192/api/system/time .

In my case time_local_sqlite3 was my actual local time but it didnā€™t mater in this case.

Fixed the problem by adding the line: date_default_timezone_set(ā€˜Europe/Stockholmā€™); in the config.php file located in the /data/grocy directory.

When the chores are tracked via the GUI, they are saved with the local time of the client (browser).

I canā€™t reinstall the addon again sighā€¦

I can add it through HACS but when I want to add the integration it just doesnā€™t worked. I tried it with my IP adress, duckdns adress, with SSL, withouth SSL with HTTPS, without HTTP, ā€¦ It just doesnā€™t workā€¦

Iā€™m having this problem too.

1 Like

After updating Home Assistant Core to version 2021.8.7, I canā€™t track my chores from the custom card anymore. Problem persists with 2021.8.8

Get the following error message:
ERROR (MainThread) [homeassistant.components.websocket_api.http.connection] [############] ā€˜zoneinfo.ZoneInfoā€™ object has no attribute ā€˜localizeā€™.

Anybody else experiencing this problem?
Have now gone back to the 2021.8.6 version and everything works again

I have noticed the same problem. Please make an issue on Github and I will try to fix as soon as I have the time.

2 Likes

Made an issue on the chores card git. Maybe its more connected to the custom component as its not possible to track them from the service tab either and not just the card.

2 Likes

Yes, if itā€™s the service call that fails itā€™s a component issue :slight_smile:

Under developer tools/service tab, I can track my chores like this with Home Assistant Core version 2021.08.08.
image
What does the entry ā€œtracked timeā€ do?
In Grocy the chores time stamp will be according the local time of the server.

Edit:

ā€œtracked_timeā€ seems to be what is missing.

Iā€™m not so familiar to this script but I just tried and added ā€œtracked_time:ā€ (with a fixed time since it does not seems to make any different) to ā€œtrackTaskā€ in the grocy-chores-card.js files and now the card works again after the Home Assistant Core 2021.8.8 update.

image

1 Like

Can confirm that worked for me too when using the call service in the developer. If i didnt use done_time I got the error but when added done_time it worked.

Thatā€™s great, it should make the fix easier. The time should be reflected in grocy, but maybe that feature was removed or changed.

I tried to remove the time from the service call altogether, but there is a problem with pygrocy for this call I think. I started a new issue there.

After update HA to 2021.9 I am not getting any Grocy information into the integration and therefore not into the card.
The only thing I have in the logs is a grocy binary sensor failed to update; nothing else.

Edit Grocy sees the API call from the integration using the API key but Iā€™m not getting any data into HA now.