Comments (6)
I think you are describing #28
It does not seems to be a timeout thing but a temporary lost of connection with the inverter which makes the connection to lose the previous authentication
from huawei_solar.
Ok, do you think my router has temporary lost the connection? Because I can not see any problems in Home Assistant. I have not looked in the code, but could it be possible to re-run the authentication code when this happens? Or reconnect to the Huawei? If not possible automatically, maybe publish a service that I could call when this happens?
from huawei_solar.
Can you look into your logs what happens to the heartbeat which keeps the session (with the authentication) open? I'm interested to see which error happens there (if any)
from huawei_solar.
Oh, yes! Sorry, I did not notice that. The heartbeat fails. And never comes back until I reloaded the Integration.
The log:
2022-05-04 12:52:30 DEBUG (MainThread) [huawei_solar.huawei_solar] Heartbeat succeeded
2022-05-04 12:52:38 DEBUG (MainThread) [huawei_solar.huawei_solar] Reading register 32064
2022-05-04 12:52:38 DEBUG (MainThread) [huawei_solar.huawei_solar] Reading register 32016
2022-05-04 12:52:38 DEBUG (MainThread) [huawei_solar.huawei_solar] Reading register 37101
2022-05-04 12:52:38 DEBUG (MainThread) [huawei_solar.huawei_solar] Reading register 37760
2022-05-04 12:52:45 DEBUG (MainThread) [huawei_solar.huawei_solar] Heartbeat succeeded
2022-05-04 12:53:08 DEBUG (MainThread) [huawei_solar.huawei_solar] Reading register 32064
2022-05-04 12:53:11 INFO (MainThread) [backoff] Backing off _do_read(...) for 2.0s (asyncio.exceptions.TimeoutError)
2022-05-04 12:53:11 DEBUG (MainThread) [huawei_solar.huawei_solar] Backing off reading for 2.0 seconds after 1 tries
2022-05-04 12:53:16 INFO (MainThread) [backoff] Backing off _do_read(...) for 2.0s (asyncio.exceptions.TimeoutError)
2022-05-04 12:53:16 DEBUG (MainThread) [huawei_solar.huawei_solar] Backing off reading for 2.0 seconds after 2 tries
2022-05-04 12:53:19 DEBUG (MainThread) [huawei_solar.huawei_solar] Reading register 32016
2022-05-04 12:53:19 DEBUG (MainThread) [huawei_solar.huawei_solar] Reading register 37101
2022-05-04 12:53:19 DEBUG (MainThread) [huawei_solar.huawei_solar] Reading register 37760
2022-05-04 12:53:49 DEBUG (MainThread) [huawei_solar.huawei_solar] Reading register 32064
2022-05-04 12:53:49 DEBUG (MainThread) [huawei_solar.huawei_solar] Reading register 32016
2022-05-04 12:53:49 DEBUG (MainThread) [huawei_solar.huawei_solar] Reading register 37101
2022-05-04 12:53:49 DEBUG (MainThread) [huawei_solar.huawei_solar] Reading register 37760
2022-05-04 12:54:19 DEBUG (MainThread) [huawei_solar.huawei_solar] Reading register 32064
2022-05-04 12:54:19 DEBUG (MainThread) [huawei_solar.huawei_solar] Reading register 32016
2022-05-04 12:54:19 DEBUG (MainThread) [huawei_solar.huawei_solar] Reading register 37101
2022-05-04 12:54:19 DEBUG (MainThread) [huawei_solar.huawei_solar] Reading register 37760
2022-05-04 12:54:49 DEBUG (MainThread) [huawei_solar.huawei_solar] Reading register 32064
2022-05-04 12:54:49 DEBUG (MainThread) [huawei_solar.huawei_solar] Reading register 32016
2022-05-04 12:54:49 DEBUG (MainThread) [huawei_solar.huawei_solar] Reading register 37101
2022-05-04 12:54:49 DEBUG (MainThread) [huawei_solar.huawei_solar] Reading register 37760
2022-05-04 12:55:19 DEBUG (MainThread) [huawei_solar.huawei_solar] Reading register 32064
2022-05-04 12:55:19 DEBUG (MainThread) [huawei_solar.huawei_solar] Reading register 32016
2022-05-04 12:55:19 DEBUG (MainThread) [huawei_solar.huawei_solar] Reading register 37101
2022-05-04 12:55:19 DEBUG (MainThread) [huawei_solar.huawei_solar] Reading register 37760
2022-05-04 12:55:49 DEBUG (MainThread) [huawei_solar.huawei_solar] Reading register 32064
2022-05-04 12:55:50 DEBUG (MainThread) [huawei_solar.huawei_solar] Reading register 32016
2022-05-04 12:55:50 DEBUG (MainThread) [huawei_solar.huawei_solar] Reading register 37101
2022-05-04 12:55:50 DEBUG (MainThread) [huawei_solar.huawei_solar] Reading register 37760
2022-05-04 12:56:20 DEBUG (MainThread) [huawei_solar.huawei_solar] Reading register 32064
2022-05-04 12:56:20 DEBUG (MainThread) [huawei_solar.huawei_solar] Reading register 32016
2022-05-04 12:56:20 DEBUG (MainThread) [huawei_solar.huawei_solar] Reading register 37101
2022-05-04 12:56:20 DEBUG (MainThread) [huawei_solar.huawei_solar] Reading register 37760
2022-05-04 12:56:50 DEBUG (MainThread) [huawei_solar.huawei_solar] Reading register 32064
2022-05-04 12:56:50 DEBUG (MainThread) [huawei_solar.huawei_solar] Reading register 32016
2022-05-04 12:56:50 DEBUG (MainThread) [huawei_solar.huawei_solar] Reading register 37101
2022-05-04 12:56:50 DEBUG (MainThread) [huawei_solar.huawei_solar] Reading register 37760
2022-05-04 12:57:20 DEBUG (MainThread) [huawei_solar.huawei_solar] Reading register 32064
2022-05-04 12:57:20 DEBUG (MainThread) [huawei_solar.huawei_solar] Reading register 32016
2022-05-04 12:57:20 DEBUG (MainThread) [huawei_solar.huawei_solar] Reading register 37101
2022-05-04 12:57:20 DEBUG (MainThread) [huawei_solar.huawei_solar] Reading register 37760
2022-05-04 12:57:50 DEBUG (MainThread) [huawei_solar.huawei_solar] Reading register 32064
2022-05-04 12:57:50 DEBUG (MainThread) [huawei_solar.huawei_solar] Reading register 32016
2022-05-04 12:57:50 DEBUG (MainThread) [huawei_solar.huawei_solar] Reading register 37101
2022-05-04 12:57:50 DEBUG (MainThread) [huawei_solar.huawei_solar] Reading register 37760
2022-05-04 12:58:20 DEBUG (MainThread) [huawei_solar.huawei_solar] Reading register 32064
2022-05-04 12:58:20 DEBUG (MainThread) [huawei_solar.huawei_solar] Reading register 32016
2022-05-04 12:58:20 DEBUG (MainThread) [huawei_solar.huawei_solar] Reading register 37101
from huawei_solar.
These errors are then coming back every 5 minutes (approx)
Sometimes with some more error rows:
2022-05-04 13:12:57 DEBUG (MainThread) [huawei_solar.huawei_solar] Backing off reading for 2.0 seconds after 1 tries
2022-05-04 13:13:01 DEBUG (MainThread) [huawei_solar.huawei_solar] Reading register 32016
2022-05-04 13:13:01 DEBUG (MainThread) [huawei_solar.huawei_solar] Reading register 37101
2022-05-04 13:13:01 DEBUG (MainThread) [huawei_solar.huawei_solar] Reading register 37760
2022-05-04 13:13:31 DEBUG (MainThread) [huawei_solar.huawei_solar] Reading register 32064
2022-05-04 13:13:34 INFO (MainThread) [backoff] Backing off _do_read(...) for 2.0s (asyncio.exceptions.TimeoutError)
2022-05-04 13:13:34 DEBUG (MainThread) [huawei_solar.huawei_solar] Backing off reading for 2.0 seconds after 1 tries
2022-05-04 13:13:39 INFO (MainThread) [backoff] Backing off _do_read(...) for 2.0s (asyncio.exceptions.TimeoutError)
2022-05-04 13:13:39 DEBUG (MainThread) [huawei_solar.huawei_solar] Backing off reading for 2.0 seconds after 2 tries
2022-05-04 13:13:44 INFO (MainThread) [backoff] Backing off _do_read(...) for 2.0s (asyncio.exceptions.TimeoutError)
2022-05-04 13:13:44 DEBUG (MainThread) [huawei_solar.huawei_solar] Backing off reading for 2.0 seconds after 3 tries
2022-05-04 13:13:49 INFO (MainThread) [backoff] Backing off _do_read(...) for 2.0s (asyncio.exceptions.TimeoutError)
2022-05-04 13:13:49 DEBUG (MainThread) [huawei_solar.huawei_solar] Backing off reading for 2.0 seconds after 4 tries
2022-05-04 13:13:51 ERROR (MainThread) [custom_components.huawei_solar] Timeout fetching BT21A0216315_data_update_coordinator data
2022-05-04 13:14:21 DEBUG (MainThread) [huawei_solar.huawei_solar] Reading register 32064
2022-05-04 13:14:24 INFO (MainThread) [backoff] Backing off _do_read(...) for 2.0s (asyncio.exceptions.TimeoutError)
2022-05-04 13:14:24 DEBUG (MainThread) [huawei_solar.huawei_solar] Backing off reading for 2.0 seconds after 1 tries
2022-05-04 13:14:29 INFO (MainThread) [backoff] Backing off _do_read(...) for 2.0s (asyncio.exceptions.TimeoutError)
2022-05-04 13:14:29 DEBUG (MainThread) [huawei_solar.huawei_solar] Backing off reading for 2.0 seconds after 2 tries
2022-05-04 13:14:34 INFO (MainThread) [backoff] Backing off _do_read(...) for 2.0s (asyncio.exceptions.TimeoutError)
2022-05-04 13:14:34 DEBUG (MainThread) [huawei_solar.huawei_solar] Backing off reading for 2.0 seconds after 3 tries
2022-05-04 13:14:39 INFO (MainThread) [backoff] Backing off _do_read(...) for 2.0s (asyncio.exceptions.TimeoutError)
2022-05-04 13:14:39 DEBUG (MainThread) [huawei_solar.huawei_solar] Backing off reading for 2.0 seconds after 4 tries
2022-05-04 13:15:11 DEBUG (MainThread) [huawei_solar.huawei_solar] Reading register 32064
2022-05-04 13:15:12 ERROR (MainThread) [huawei_solar.huawei_solar] Could not read register value, has another device interrupted the connection?
2022-05-04 13:15:42 DEBUG (MainThread) [huawei_solar.huawei_solar] Reading register 32064
2022-05-04 13:15:42 DEBUG (MainThread) [huawei_solar.huawei_solar] Reading register 32016
2022-05-04 13:15:42 DEBUG (MainThread) [huawei_solar.huawei_solar] Reading register 37101
2022-05-04 13:15:42 DEBUG (MainThread) [huawei_solar.huawei_solar] Reading register 37760
from huawei_solar.
A small typo prevented the existing re-login logic from working. I've also implemented a secondary retry to make it even more robust: https://gitlab.com/Emilv2/huawei-solar/-/commit/22bd9b4b0e38f69a2206f11e28eeed415cb2644d . I've upgraded the huawei-solar library to 2.0.1 in 1.0.1 of this integration.
from huawei_solar.
Related Issues (20)
- [Bug]: forcible_charge_soc service does not seem to work HOT 1
- [Bug]: name 'bridge' is not defined HOT 2
- [Feature Request]: Expose services for other Active Power Control modes HOT 2
- [Bug]: all values in read only mode when connecting via sun2000-<serial_no> WiFi
- [Bug]: Integration cannot start after update of HA core to version Home Assistant 2023.6.0 Supervisor 2023.06.1 Operating System 10.2 Frontend 20230607.0 - latest HOT 1
- [Bug]: Everytime the refresh happens the sensor data get unavailable
- [Bug]: HA Core 2023.6.1 fails to start integration HOT 8
- [Bug]: Integration crashes when trying to connect via modbus rtu
- [Bug]: Impossibile caricare il flusso di configurazione: {"message":"Invalid handler specified"} HOT 2
- [Feature Request]: Backup Power SOC entity HOT 11
- [Feature Request]: Need to track "Internal_Temperature" of inverter
- [Bug]: Small failure in script for Inverter polling frequency
- [Bug]: Integration crashes after updating HA to 2023.7 HOT 19
- Cant connect with sin 2000 [Bug]: HOT 2
- [Bug]: Setup failed for custom integration huawei_solar HOT 1
- [Bug]: object NoneType can't be used in 'await' expression" HOT 2
- [Bug]: Integration crashes from time to time HOT 16
- [Bug]: Error occurred loading flow for integration huawei_solar HOT 1
- [Feature Request]: Import historical data and fill the gaps is recorder (statistics) HOT 5
- [Bug]: failed to setup HOT 6
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from huawei_solar.