metbosch / homebridge-http-temperature

HomeBridge HomeKit Plugin for HTTP temperature endpoints
https://www.npmjs.com/package/homebridge-http-temperature
Apache License 2.0
33 stars 18 forks source link

Any way to modify the log level? #22

Closed jlg89 closed 2 years ago

jlg89 commented 4 years ago

Nice plugin, simple and effective. I appreciate the work that's gone into it.

This is a completely non-critical issue, but is there any way to change the logging behavior? The default is fairly verbose, and it does clutter the log file a bit.

metbosch commented 3 years ago

There is no support for that, which messages do you will expect?

jlg89 commented 3 years ago

I see a log entry every time the plugin pulls the temperature reading. Seems like it should only log errors unless verbose logging is enabled.

kls1003 commented 2 years ago

is the problem still being worked on? The homebridge log file explodes when using multiple sensors ...

metbosch commented 2 years ago

Could someone test branch feat/debug_log? I'm not using homebridge, so I cannot test the plugin now.

kls1003 commented 2 years ago

Great!! I would like to test it, unfortunately, I do not know how I get the plugin in the homebridge.

Klaus

Am 13.01.2022 um 19:40 schrieb metbosch @.***>:

 Could someone test branch feat/debug_log? I'm not using homebridge, so I cannot test the plugin now.

— Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you commented.

metbosch commented 2 years ago

@kls1003 Thanks for your interest. It will depend on your setup, but the overall idea is replace the current index.js file that you have by the new one.
First, you need to locate where npm (the nodejs package manager) stores the homebridge dependencies. It may be /var/lib/homebridge/node_modules, /home/homebridge/XXX, etc. You can use the following command to search within a path find /path/where/to/search -name homebridge-http-temperature. Then, you have to backup the current index.js file, and place there the new one. Finally, restart homebridge service and check if logs have disapeared.

kls1003 commented 2 years ago

so easy :-)

It works great for me. Thank you for this quick implementation.

A little hint: The "Temperature Sensor Addon for Shelly 1/1PM" works with:

"field_name": "[ext_temperature].[0].[tC]“ (first sensor) "field_name": "[ext_temperature].[1].[tC]“ (second sensor) "field_name": "[ext_temperature].[2].[tC]“ (third sensor)

(by using the status url: ip/status)

{ "accessory": "HttpTemperature", "name": "hot water (reverse)“, "url": "http://192.168.178.43/status", "field_name": "[ext_temperature].[0].[tC]", "manufacturer": "Shelly", "auth": { "user": "myUser“, "pass": "myPassword“ } }

I haven't found any other plugin that does this so well.

Klaus

Am 14.01.2022 um 07:48 schrieb metbosch @.***>:

@kls1003 https://github.com/kls1003 Thanks for your interest. It will depend on your setup, but the overall idea is replace the current index.js file that you have by the new one. First, you need to locate where npm (the nodejs package manager) stores the homebridge dependencies. It may be /var/lib/homebridge/node_modules, /home/homebridge/XXX, etc. You can use the following command to search within a path find /path/where/to/search -name homebridge-http-temperature. Then, you have to backup the current index.js file, and place there the new one https://github.com/metbosch/homebridge-http-temperature/blob/feat/debug_log/index.js. Finally, restart homebridge service and check if logs have disapeared.

— Reply to this email directly, view it on GitHub https://github.com/metbosch/homebridge-http-temperature/issues/22#issuecomment-1012817867, or unsubscribe https://github.com/notifications/unsubscribe-auth/ATSN4ZG36NRDA2MYUOZFA7LUV7BLJANCNFSM4QE4RSSA. You are receiving this because you were mentioned.

metbosch commented 2 years ago

Fix published as version 0.8.0 in npm https://www.npmjs.com/package/homebridge-http-temperature