-
Notifications
You must be signed in to change notification settings - Fork 427
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
Request Timeout or "Cloud ERROR 504" for POW devices #1563
Comments
Device ID: 1001d4cc4c The moment I enabled energy, it shut down. Logger: custom_components.sonoff.core.ewelink.cloud |
Without debug logs, it's useless. It is necessary to understand after which request this error occurs. And what about the device? Does it physically switch off? Or does it just become temporarily unavailable in the HA? |
It switch off. Like someone trigger it. |
Currently I solved it by deleting and reconnecting the device on the ewelink App and disabling the Energy entity. For now I prefer not to touch anything anymore. However I follow this issue carefully. |
That was the first thing I did, but the problem reapears after 12? hours... |
I had deleted the energy entity, but the problem persisted. When I deleted the device on the ewelink App and reconnected it started working. It has been working regularly for 48 hours now. |
Right now I have only disable the sensor on device, nothing else and it had stopped. |
@vegos In my case it kept deactivating until I disconnected and reconnected on the App. The strange thing is that I have been using it for 3 years without problems and in these days I have not done any updates (not even the device's fw) |
Yeap, me too. It was working fine... |
So it can be cloud problem. If nothing other have been changed. |
After reconnecting, the only thing done was to deactivate the energy entities, but it might have been useless. Honestly, I don't have the courage to reactivate the entities. 😅 Yes, it could also be just a Cloud problem. However, on the sonoff pages, no one has complained |
The problem with my appears exactly every 5 days. At the moment, have an automation let HA turn it back on because I have been trying understand what is happening for months also i'm too lazy to replace it (Sonoff just sent me a new one after weeks of troubleshooting they said that was related to the integration making too many requests) Device: 100179eb80 It just happened. On Sunday, I will try to enable debug to see what we get there This is the diagnostic. {
"home_assistant": {
"installation_type": "Home Assistant OS",
"version": "2024.10.3",
"dev": false,
"hassio": true,
"virtualenv": false,
"python_version": "3.12.4",
"docker": true,
"arch": "aarch64",
"timezone": "Europe/Rome",
"os_name": "Linux",
"os_version": "6.6.62-haos-raspi",
"supervisor": "2024.12.3",
"host_os": "Home Assistant OS 14.1",
"docker_version": "27.2.0",
"chassis": "embedded",
"run_as_root": true
},
"custom_components": {
"hacs": {
"documentation": "https://hacs.xyz/docs/configuration/start",
"version": "2.0.1",
"requirements": [
"aiogithubapi>=22.10.1"
]
},
"sonoff": {
"documentation": "https://github.com/AlexxIT/SonoffLAN",
"version": "3.8.1",
"requirements": [
"pycryptodome>=3.6.6"
]
}
},
"integration_manifest": {
"domain": "sonoff",
"name": "Sonoff",
"codeowners": [
"AlexxIT"
],
"config_flow": true,
"dependencies": [
"http",
"zeroconf"
],
"documentation": "https://github.com/AlexxIT/SonoffLAN",
"iot_class": "local_push",
"issue_tracker": "/api/sonoff/7e7aeb65-8ba6-4611-aa82-c4857bdb6f2b",
"requirements": [
"pycryptodome>=3.6.6"
],
"version": "3.8.1",
"is_built_in": false
},
"setup_times": {
"null": {
"setup": 0.0004439410040504299
},
"01JGMYDCVD0G55S6QHFHWEQAZE": {
"wait_import_platforms": -0.0002904049979406409,
"wait_base_component": -4.7589430259977235,
"config_entry_setup": 5.932352008007001
}
},
"data": {
"version": "ffa7e22",
"cloud_auth": true,
"config": null,
"options": {
"mode": "auto",
"debug": true
},
"errors": [
{
"name": "custom_components.sonoff.core.ewelink.cloud",
"message": [
"Cloud ERROR: {'error': 504, 'reason': 'Request Timeout', 'deviceid': 'xxx', 'apikey': 'xxx', 'sequence': '1736859748852'}",
"Cloud ERROR: {'error': 504, 'reason': 'Request Timeout', 'deviceid': 'xxx', 'apikey': 'xxx', 'sequence': '1736860138868'}",
"Cloud ERROR: {'error': 504, 'reason': 'Request Timeout', 'deviceid': 'xxx', 'apikey': 'xxx', 'sequence': '1736871301897'}",
"Cloud ERROR: {'error': 504, 'reason': 'Request Timeout', 'deviceid': 'xxx', 'apikey': 'xxx', 'sequence': '1736876612315'}",
"Cloud ERROR: {'error': 504, 'reason': 'Request Timeout', 'deviceid': 'xxx', 'apikey': 'xxx', 'sequence': '1736893022887'}"
],
"level": "WARNING",
"source": [
"custom_components/sonoff/core/ewelink/cloud.py",
616
],
"timestamp": 1736893027.9040115,
"exception": "",
"count": 6,
"first_occurred": 1736859633.864911
}
],
"devices": {
"xxx": {
"uiid": 190,
"params": {
"bindInfos": "***",
"version": 8,
"demNextFetchTime": 1736892000000,
"ssid": "***",
"bssid": "***",
"fwVersion": "1.1.1",
"switches": [
{
"switch": "on",
"outlet": 0
}
],
"configure": [
{
"startup": "off",
"outlet": 0
}
],
"pulses": [
{
"pulse": "off",
"switch": "off",
"outlet": 0,
"width": 500
}
],
"sledOnline": "on",
"staMac": "***",
"rssi": -67,
"threshold": {
"actPow": {
"min": 10,
"max": 500000
},
"voltage": {
"min": 16500,
"max": 27700
},
"current": {
"min": 10,
"max": 2100
}
},
"overload_00": {
"minAP": {
"en": 0,
"val": 10
},
"maxAP": {
"en": 1,
"val": 500000
},
"minV": {
"en": 0,
"val": 16500
},
"maxV": {
"en": 0,
"val": 27700
},
"maxC": {
"en": 1,
"val": 2100
},
"minC": {
"en": 0,
"val": 10
}
},
"current": 332,
"voltage": 22249,
"power": 60202,
"uiActive": 60,
"timeZone": 2,
"dayKwh": 592,
"monthKwh": 5056,
"getHoursKwh": {
"start": 0,
"end": 743
},
"operSide": 1,
"devPushType": 2
},
"model": "POWR320D",
"online": true,
"local": null,
"localtype": null,
"host": null
}
}
}
} |
No one ever sends in the debug logs. Without them, the search for the problem is meaningless. |
I have send them already. |
On Sunday, when the problem occurs again, I will post the debug logs. I thought debugging was enabled, but when I checked the extension page, it was not. |
@vegos you right. My bad. Missed that. Thanks! |
@vegos Do you have custom settings for getting energy? By default, energy should be requested once per hour. In your logs it is requested every 1-2 minutes. |
No, I don't. I just enabled the sensor on your integration. Nothing else is running. |
Maybe something changed in the cloud. It's definitely not supposed to work that way. |
@AlexxIT have shared mine. According to my calculations, it will go offline tomorrow (Sunday 19th) at 23:15 UTC. |
Same issues with older POWR2. 100090c4da > is the POWR2 with issues. Suddenly stopped communicating, via APP it's still possible to turn off/on (sometimes?), no measuring values in app. No control in HA. [edit]
|
After some restarting, power off/on, re-connect to network, etc most values are comming in HA again. Only the ENERGY value is still unknown in HA. Following message remain in debug log.
|
I've had the same problem. After months of working, my smartplugs didn't refresh the power/energy values. It only refreshed after opening the Ewelink app and opening the specific device page. It's working again for me (for now). A simple HA restart did the trick. Now all smart plugs are being refreshed every x seconds. The error I had:
|
I noticed that after "restart" of the POW, it starts on OFF position and the Default action is turned to OFF (I set it to ON after power loss / it doesn't keep up after restart). |
Did you try to set this device behavior setting through the Ewelink app? |
Yes, I setup on the ewelink app, it looks ok but after power off, it defaults to off... |
I just tested this behavior on my end and it works as expected. Im not sure if your issue is related to HA.. |
I was able to get some debug logs:
as you can see the entity go off when the alert power off has been raised |
POWR2 and POW316: Does not switch erratically, but the power and current and voltage values are not always updated. I switch the device off and it shows the last power value for many hours still in HA. The "energy" or "energy_day" attribute seems to be updated correctly. I notice also that as soon as the Ewelink app (with these devices) is opened somewhere, the power and current updates to the correct values in HA. Home Assistant:
I list only the POWR2 debug log extracts, as it seems there are POW316 debug logs already. POWR2
Debug log: |
@HennieMouton seems, if it is, a completely different issue, why posting it here? |
"errors": [ { "name": "custom_components.sonoff.core.ewelink.cloud", "message": [ "Cloud ERROR: {'error': 504 .... as per the title of this thread. |
I also got the 504 cloud error (so far only once) on a S60TPF plug... The device seems to be functioning OK and data is available in HA. Not sure what is causing this. |
It has been noticed that some POW devices switch off after being queried for current power values.
In the debug logs it looks like this:
At this point, the known model:
Please let me know if your POW devices have a similar problem.
Be sure to attach the UIID of your model (or device diagnostics). And debug logs that illustrate the problem.
Posts without details will be ignored. Posts not about POW devices will be deleted.
Maybe something is broken in cloud updates or firmware updates for your devices. And these requests need to be disabled.
Unfortunately, you'll lose the actual power data, but at least your devices will still work.
PS. Unfortunately I don't use POW devices at all. I can't find the problem myself.
The text was updated successfully, but these errors were encountered: