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
Prevent crash where createdAt is not returned #9
Conversation
Hi boc - This did not resolve the problem for me? I'm still getting exactly the same error log. |
What post code Stuart?
…On Mon, 20 Jul 2020, 14:24 stuarts0011, ***@***.***> wrote:
Hi boc - This did not resolve the problem for me? I'm still getting
exactly the same error log.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
<#9 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AA2RMNCGMBMWS3NCP4K7KPDR4PBG7ANCNFSM4OXCD62Q>
.
|
2069
Sometimes it will load the platform, sometimes not.
…On Mon, 20 Jul 2020, 3:04 pm boc-the-git, ***@***.***> wrote:
What post code Stuart?
On Mon, 20 Jul 2020, 14:24 stuarts0011, ***@***.***> wrote:
> Hi boc - This did not resolve the problem for me? I'm still getting
> exactly the same error log.
>
> —
> You are receiving this because you authored the thread.
> Reply to this email directly, view it on GitHub
> <
#9 (comment)
>,
> or unsubscribe
> <
https://github.com/notifications/unsubscribe-auth/AA2RMNCGMBMWS3NCP4K7KPDR4PBG7ANCNFSM4OXCD62Q
>
> .
>
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
<#9 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AM3WSCS6EPQMOT53HKICVZLR4PF5TANCNFSM4OXCD62Q>
.
|
I've tested with 2069 and no issue. As you say it sometimes works and sometimes doesn't, can you look to supply more info next time it crashes? Without more info, I can only assume it's unrelated. It would also be useful to get the output from this.. please create a python script with this and run it:
|
If the error exists on reboot, it won't load the platform as here: "Log Details (ERROR) Error while setting up amberelectric platform for sensor If it happens after successfully loading the platform, it just doesn't return data on that request. |
The output from your python above is as expected. |
Thanks for the extra information @stuarts0011 What I can infer from that is you are not running my code. I guess this is why you are getting the exact same (to the line of code) error message as my original error - because it was before my code change. Your error message referencing line 315 of ambermodel.py is referencing the current/original code, not my modified code. If you update your ambermodel.py as per my change (see the 'Files changed' tab), you should no longer get the error. |
Hahaa. I left the original line 315 in and added your extra lines, but I realise I was meant to delete the original line 315. Sorry and thanks. |
No worries @stuarts0011 ! I'll assume that my change does fix your issue then unless we hear otherwise :) |
I will admit this isn't extensively tested because I don't know the overall solution too well, but I can confirm this fixes the issue as reported here: https://community.home-assistant.io/t/amber-electric-australia-custom-component/201231/18