StealthChesnut / HA-FoxESS-Modbus

Home Assistant Modbus Integration setup for Fox ESS H1 and AC Inverters
76 stars 37 forks source link

Fixing typo #44

Closed Ndrinta closed 1 year ago

Ndrinta commented 1 year ago

In the definition of the sensor system_losses there is a typo in the usage of sensor.feed_in_power. It's now been fixed.

StealthChesnut commented 1 year ago

Thanks for these - will review!

Get Outlook for Androidhttps://aka.ms/AAb9ysg


From: Ndrinta @.> Sent: Sunday, August 28, 2022 3:30:30 PM To: StealthChesnut/HA-FoxESS-Modbus @.> Cc: Subscribed @.***> Subject: [StealthChesnut/HA-FoxESS-Modbus] Fixing typo (PR #44)

In the definition of the sensor system_losses there is a typo in the usage of sensor.feed_in_power. It's now been fixed.


You can view, comment on, or merge this pull request online at:

https://github.com/StealthChesnut/HA-FoxESS-Modbus/pull/44

Commit Summary

File Changes

(1 filehttps://github.com/StealthChesnut/HA-FoxESS-Modbus/pull/44/files)

Patch Links:

— Reply to this email directly, view it on GitHubhttps://github.com/StealthChesnut/HA-FoxESS-Modbus/pull/44, or unsubscribehttps://github.com/notifications/unsubscribe-auth/ALFO3FHKFYVSTWZEHPXZ573V3NSXNANCNFSM573CQJXA. You are receiving this because you are subscribed to this thread.Message ID: @.***>

Ndrinta commented 1 year ago

Wait, I don't think I understand. In configuration.yaml you define a template sensor named feed_in_power. Then you define another template sensor named system_losses which uses a non-existent sensor named sensor.feedin_power.

Either you change the actual sensor name or its usage in the system_losses's value_template definition.

StealthChesnut commented 1 year ago

Aha - I'll re-check it. Thanks for coming back with the extra info.

Ndrinta commented 1 year ago

It's alright. If I may, can we come up with a solution and you let me do another pull request? I'm looking forward to committing my first actual bug fix 😊 cheers

Daibutt commented 1 year ago

@StealthChesnut Chris, this is a change to the original code which was feedin_power, if I'm not mistaken? This link contains some dialogue when the losses sensor was being discussed. Unless it was just my config that was called feedin_power. https://github.com/StealthChesnut/HA-FoxESS-Modbus/discussions/9

I guess as long as it's consistent throughout it doesn't matter. If I have to reinstall this I'll check any templates that use feedin_power.

StealthChesnut commented 1 year ago

It is. I currently have feed_in_power as the sensor name in my live config, so I was going to go with accepting the change here. I'm not sure where along the lines that's got changed if yours is feedin_power.

Daibutt commented 1 year ago

@StealthChesnut Ignore me! Looking back at earlier code it seems it was feed_in_power from before or around V1.0!? Guess my feedin_power was from the earlier work, hence the issue with the losses sensor, as that's what I called it in there. Ooops.

StealthChesnut commented 1 year ago

Haha - no probs!