fuatakgun / eufy_security

Home Assistant integration to manage Eufy Security devices as cameras, home base stations, doorbells, motion and contact sensors.
877 stars 73 forks source link

Eufy integration stopped working (2K Wired/T8424) #896

Closed Xitro01 closed 10 months ago

Xitro01 commented 12 months ago

Can't get the integration back working again, I have the following errors in my integration logs:

 TypeError  Cannot read properties of undefined (reading 'value')
error stack:
• device.ts:626 getRawProperty
    usr/src/app/node_modules/eufy-security-client/src/http/device.ts:626:41
• device.ts:106 handlePropertyChange
    usr/src/app/node_modules/eufy-security-client/src/http/device.ts:106:38
• device.ts:1632 handlePropertyChange
    usr/src/app/node_modules/eufy-security-client/src/http/device.ts:1632:15
• device.ts:2050 handlePropertyChange
    usr/src/app/node_modules/eufy-security-client/src/http/device.ts:2050:15
• device.ts:79 updateProperty
    usr/src/app/node_modules/eufy-security-client/src/http/device.ts:79:22
• device.ts:152 updateRawProperty
    usr/src/app/node_modules/eufy-security-client/src/http/device.ts:152:30
• device.ts:66 <anonymous>
    usr/src/app/node_modules/eufy-security-client/src/http/device.ts:66:22
• device.ts:65 update
    usr/src/app/node_modules/eufy-security-client/src/http/device.ts:65:35
• device.ts:39 initializeState
    usr/src/app/node_modules/eufy-security-client/src/http/device.ts:39:14
{
  metadata: {
    key: 2005,
    name: 'hidden-motionDetectionSensitivity',
    label: 'HIDDEN Motion Detection Sensitivity',
    readable: true,
    writeable: false,
    type: 'number',
    min: 1,
    max: 3
  },
  oldValue: undefined,
  newValue: 2
}
2023-08-21 10:35:35.380  INFO  Connected to station T8200N0021180F2B on host 192.168.1.45 and port 29324 
2023-08-21 10:35:36.855  INFO  Push notification connection successfully established 

Running HA version: 2023.8.3. Integration version: 7.0.4. Add-on version: 1.6.3. RTSP add-on version: 0.17.6.

Hereby the add-on logs:

2023-08-21 10:35:35.380  INFO  Connected to station T8200N0021180F2B on host 192.168.1.45 and port 29324 
2023-08-21 10:35:36.855  INFO  Push notification connection successfully established 
2023-08-21 10:36:06.453  INFO  Stopping the station stream for the device T8200N0021180F2B, because we haven't received any data for 5000 seconds 
2023-08-21 10:36:06.665  ERROR Message error 
 LivestreamNotRunningError  Livestream for device T8200N0021180F2B could not be stopped, because it is not running
error stack:
• message_handler.ts:240 handle
    usr/src/app/node_modules/eufy-security-ws/src/lib/device/message_handler.ts:240:31
• task_queues:96 processTicksAndRejections
    node:internal/process/task_queues:96:5
• server.ts:125 receiveMessage
    usr/src/app/node_modules/eufy-security-ws/src/lib/server.ts:125:21
2023-08-21 10:36:14.127  INFO  Disconnected from station T8200N0021180F2B 
2023-08-21 10:36:34.185  WARN Station T8200N0021180F2B - Tried all hosts, no connection could be established 
2023-08-21 10:36:34.186  INFO  Timeout connecting to station T8200N0021180F2B 
2023-08-21 10:36:49.298  INFO  Connected to station T8200N0021180F2B on host 52.58.242.75 and port 14304 
2023-08-21 10:37:13.362  INFO  Stopping the station stream for the device T8200N0021180F2B, because we haven't received any data for 5000 seconds 
2023-08-21 10:37:31.259  INFO  Client disconnected with ip: 127.0.0.1 port: 36084 code: 1000 reason: Normal Closure 
2023-08-21 10:42:20.822  INFO  Client disconnected with ip: 127.0.0.1 port: 47398 code: 1000 reason: Normal Closure 
2023-08-21 10:42:41.148  INFO  Stopping the station stream for the device T8200N0021180F2B, because we haven't received any data for 5000 seconds 
2023-08-21 10:42:43.678  ERROR Message error 
 LivestreamNotRunningError  Livestream for device T8200N0021180F2B could not be stopped, because it is not running
error stack:
• message_handler.ts:240 handle
    usr/src/app/node_modules/eufy-security-ws/src/lib/device/message_handler.ts:240:31
• task_queues:96 processTicksAndRejections
    node:internal/process/task_queues:96:5
• server.ts:125 receiveMessage
    usr/src/app/node_modules/eufy-security-ws/src/lib/server.ts:125:21
2023-08-21 10:44:55.837  INFO  Client disconnected with ip: 127.0.0.1 port: 59654 code: 1000 reason: Normal Closure 
2023-08-21 10:44:57.811  INFO  Client disconnected with ip: 127.0.0.1 port: 39252 code: 1000 reason: Normal Closure 
2023-08-21 10:45:22.746  INFO  Client disconnected with ip: 127.0.0.1 port: 39268 code: 1000 reason: Normal Closure 
2023-08-21 10:45:24.682  INFO  Client disconnected with ip: 127.0.0.1 port: 36496 code: 1000 reason: Normal Closure 
2023-08-21 10:45:36.608  INFO  Stopping the station stream for the device T8200N0021180F2B, because we haven't received any data for 5000 seconds 
2023-08-21 10:45:41.205  ERROR Message error 
 LivestreamNotRunningError  Livestream for device T8200N0021180F2B could not be stopped, because it is not running
error stack:
• message_handler.ts:240 handle
    usr/src/app/node_modules/eufy-security-ws/src/lib/device/message_handler.ts:240:31
• task_queues:96 processTicksAndRejections
    node:internal/process/task_queues:96:5
• server.ts:125 receiveMessage
    usr/src/app/node_modules/eufy-security-ws/src/lib/server.ts:125:21
2023-08-21 10:45:46.432  INFO  Client disconnected with ip: 127.0.0.1 port: 36500 code: 1000 reason: Normal Closure 
2023-08-21 10:46:54.688  INFO  Client disconnected with ip: 127.0.0.1 port: 36296 code: 1006 reason: Abnormal Closure 
2023-08-21 10:46:54.690  INFO  Client disconnected with ip: 127.0.0.1 port: 36386 code: 1006 reason: Abnormal Closure 
2023-08-21 10:46:54.704  INFO  Client disconnected with ip: 127.0.0.1 port: 36416 code: 1006 reason: Abnormal Closure 
AdzRayner commented 12 months ago

I'm having the same issue after updating OS and Eufy

Home Assistant 2023.8.3 Supervisor 2023.08.1 Operating System 10.5 Frontend 20230802.1 - latest

Mine is saying invalid API Response

obviousman771 commented 12 months ago

I am seeing the same issue as well, identical error messages to what Xitro01 posted. I believe the problems started when the eufy-security-ws addon updated to version 1.6.3. From the logs:

2023-08-21 15:07:47.059 ERROR Device handlePropertyChange error TypeError Cannot read properties of undefined (reading 'value') error stack: • device.ts:626 getRawProperty usr/src/app/node_modules/eufy-security-client/src/http/device.ts:626:41 • device.ts:106 handlePropertyChange usr/src/app/node_modules/eufy-security-client/src/http/device.ts:106:38 • device.ts:1632 handlePropertyChange usr/src/app/node_modules/eufy-security-client/src/http/device.ts:1632:15 • device.ts:2050 handlePropertyChange usr/src/app/node_modules/eufy-security-client/src/http/device.ts:2050:15 • device.ts:79 updateProperty usr/src/app/node_modules/eufy-security-client/src/http/device.ts:79:22 • device.ts:152 updateRawProperty usr/src/app/node_modules/eufy-security-client/src/http/device.ts:152:30 • device.ts:66 usr/src/app/node_modules/eufy-security-client/src/http/device.ts:66:22 • device.ts:65 update usr/src/app/node_modules/eufy-security-client/src/http/device.ts:65:35 • device.ts:39 initializeState usr/src/app/node_modules/eufy-security-client/src/http/device.ts:39:14 { metadata: { key: 2005, name: 'hidden-motionDetectionSensitivity', label: 'HIDDEN Motion Detection Sensitivity', readable: true, writeable: false, type: 'number', min: 1, max: 3 }, oldValue: undefined, newValue: 1 }

Xitro01 commented 12 months ago

I would like to add that I’m running a custom port (8556), but the logs of the add-on keep showing me the default port (8554). Not sure if this has anything to do with it.

kvanbiesen commented 12 months ago

I would like to add that I’m running a custom port (8556), but the logs of the add-on keep showing me the default port (8554). Not sure if this has anything to do with it.

thats norman, inside the docker container the service always runs ons port 8554, it just get mapped to the outside world to 8556. That is something the sofware is unaware of and reports 8554 cuase its running on that port.

if you do a docker ps -a you should see the container with the port 8554 -> 8556 mapped

btw simlar error here also with floodlight, eveything is still working besides the stream. IT always gets stuck on preparing now and i ahve to reboot the light in orde to make it back to IDLE. tus StreamStatus.PREPARING

asnt like this in the previous buiild but i assume thats a bropat issue?

Xitro01 commented 12 months ago

I would like to add that I’m running a custom port (8556), but the logs of the add-on keep showing me the default port (8554). Not sure if this has anything to do with it.

thats norman, inside the docker container the service always runs ons port 8554, it just get mapped to the outside world to 8556. That is something the sofware is unaware of and reports 8554 cuase its running on that port.

if you do a docker ps -a you should see the container with the port 8554 -> 8556 mapped

btw simlar error here also with floodlight, eveything is still working besides the stream. IT always gets stuck on preparing now and i ahve to reboot the light in orde to make it back to IDLE. tus StreamStatus.PREPARING

asnt like this in the previous buiild but i assume thats a bropat issue?

Thanks for that clarification!

obviousman771 commented 12 months ago

Just fyi, I reverted my HA to a previous backup that used uefy-security-ws version 1.6.2 and everything is working again. It was definitly the 1.6.3 update that broke this doorbell.

kvanbiesen commented 12 months ago

I've share my light with bropat and he's looking into it. Since he doesn't have a floodlight 2k, it's hard for him to test.

I doubt anything works with the 1.6.3 and the floodlight 2k. He says because a shitload is getting send unencrypted. Pretty sure he'll find it :-)

On Tue, Aug 22, 2023, 19:50 obviousman771 @.***> wrote:

Just fyi, I reverted my HA to a previous backup that used uefy-security-ws version 1.6.2 and everything is working again. It was definitly the 1.6.3 update that broke this doorbell.

— Reply to this email directly, view it on GitHub https://github.com/fuatakgun/eufy_security/issues/896#issuecomment-1688652064, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABZ4API5RVWQZNC6K7MMAULXWTWPTANCNFSM6AAAAAA3YGASUU . You are receiving this because you commented.Message ID: @.***>

dbustosrc commented 12 months ago

Hi, here I'm another 2K wired user with the exactly same problem, and also the configuration of port 8556.

kvanbiesen commented 12 months ago

Rollback to 1.6.2. Then it works Bropat is looking for a fix.

Some devices usin P2P encryption where the floodlight isnt. He'gonna look for it this weekend when he has some times and using my floodlight to test (he doesnt have the hardware)

AlTyndall commented 11 months ago

Rollback to 1.6.2. Then it works Bropat is looking for a fix.

Some devices usin P2P encryption where the floodlight isnt. He'gonna look for it this weekend when he has some times and using my floodlight to test (he doesnt have the hardware)

Any pointers as to how to roll back an Add On? I'm not up for rolling my whole HA system back to the latest pre 1.6.3 update, just the add on. If it can be done without uninstalling and reinstalling then so much the better - it's been a while since I set it up and would rather not encounter any gremlins along the way since my other Eufy devices are fine.

kvanbiesen commented 11 months ago

Uninstall the addon Settings - system - backups. Restore backup from the eufy_security_ws_162 and be done

On Sat, Aug 26, 2023, 11:29 AlTyndall @.***> wrote:

Rollback to 1.6.2. Then it works Bropat is looking for a fix.

Some devices usin P2P encryption where the floodlight isnt. He'gonna look for it this weekend when he has some times and using my floodlight to test (he doesnt have the hardware)

Any pointers as to how to roll back an Add On? I'm not up for rolling my whole HA system back to the latest pre 1.6.3 update, just the add on. If it can be done without uninstalling and reinstalling then so much the better - it's been a while since I set it up and would rather not encounter any gremlins along the way since my other Eufy devices are fine.

— Reply to this email directly, view it on GitHub https://github.com/fuatakgun/eufy_security/issues/896#issuecomment-1694241663, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABZ4APKP23WAW3EYHXVDDADXXG6WVANCNFSM6AAAAAA3YGASUU . You are receiving this because you commented.Message ID: @.***>

fuatakgun commented 11 months ago

If this is the first time of installation of add-on, which means no backup of previous version, there is no easy way to downgrade

AlTyndall commented 11 months ago

Thanks both. Successfully rolled back to 1.6.2 and all working as expected again. (Also needed to then reload Eufy integration after restoring 1.6.2).

AlTyndall commented 11 months ago

Thanks both. Successfully rolled back to 1.6.2 and all working as expected again. (Also needed to then reload Eufy integration after restoring 1.6.2).

Grrr! It auto updated back to 1.6.3! Now unchecked.

david-b13 commented 11 months ago

+1 for integration stopped working. Upgraded to new OS and HA releases in the last day or two, and noticed eufy cameras and doorbell not working.

fuatakgun commented 11 months ago

This issue is about add-on updates not home assistant or hassos updates.

kvanbiesen commented 11 months ago

IF your homebase is upgrade, you need 1.6.3 but will break most non homebase devices. If your homebase isnt upgraded, stick to 1.6.2, then everything works fine.

LAtest HA and OS here

On Mon, Aug 28, 2023 at 10:00 PM david-b13 @.***> wrote:

+1 for integration stopped working. Upgraded to new OS and HA releases in the last day or two, and noticed eufy cameras and doorbell not working.

— Reply to this email directly, view it on GitHub https://github.com/fuatakgun/eufy_security/issues/896#issuecomment-1696320041, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABZ4APJJU2MMF6AOJTSR5TLXXT2FFANCNFSM6AAAAAA3YGASUU . You are receiving this because you commented.Message ID: @.***>

AlTyndall commented 11 months ago

IF your homebase is upgrade, you need 1.6.3 but will break most non

homebase devices.

If your homebase isnt upgraded, stick to 1.6.2, then everything works fine.

My HomeBase is 3.2.9.5h and seems to be fine with the Eufy integration. Not going to even see what the potential upgrade version is in case it just applies it and then I'm stuck with only either it working on 1.6.3 or the Floodlight Cam 2k working in 1.6.2!

DaveR2419 commented 11 months ago

I have same issue with update for 2k wired.

witold-gren commented 11 months ago

Hey, I also have the similar issue, but in my case I lost ability to control HomeBase station. Even if I back to previous version it still don't work.. do you know haw I can fix this issue? Also I lost information about battery level in all cameras and sensors.

HomeBase is 3.2.9.5h Eufy T8151: 1.1.3.7

Eufy Security: 7215e27 (latest version) eufy-security-ws: 1.6.2

Home Assistant 2023.8.4 Supervisor 2023.08.1 Operating System 10.5 Frontend: 20230802.1 - latest

image image
kvanbiesen commented 11 months ago

Bropat has fixed the issue with encrypted and non encrypted devices, he Will update soon

On Thu, Aug 31, 2023, 14:27 Witold Gren @.***> wrote:

Hey, I also have the similar issue, but in my case I lost ability to control HomeBase station. Even if I back to previous version it still don't work.. do you know haw I can fix this issue? Also I lost information about battery level in all cameras and sensors.

HomeBase is 3.2.9.5h Eufy T8151: 1.1.3.7

Eufy Security: 7215e27 https://github.com/fuatakgun/eufy_security/commit/7215e274c6e2730dd0bd2376fd27c07badc9178d (latest version) eufy-security-ws: 1.6.2

Home Assistant 2023.8.4 Supervisor 2023.08.1 Operating System 10.5 Frontend: 20230802.1 - latest [image: image] https://user-images.githubusercontent.com/2304938/264642174-378613a3-5c30-4707-9400-afdb5f177d50.png [image: image] https://user-images.githubusercontent.com/2304938/264642613-03e28e63-3794-48f3-869d-6beca27d3e6e.png

— Reply to this email directly, view it on GitHub https://github.com/fuatakgun/eufy_security/issues/896#issuecomment-1700942280, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABZ4APODTXQKJQ6EBZIXAJ3XYB7MVANCNFSM6AAAAAA3YGASUU . You are receiving this because you commented.Message ID: @.***>

AdzRayner commented 11 months ago

All working perfect after the update.

Running Homebase 2 Video Doorbell S330 eufyCam 2C Pro

dbustosrc commented 11 months ago

The las release 1.6.4 fixed the problem on my Doorbell 2K Wired T8200

witold-gren commented 11 months ago

Unfortunately, my cameras still don't work after updating the add-on.

kvanbiesen commented 11 months ago

Everything working here. Remembering after updating vropad addon you have to restart the EUFY addon as well

On Sat, Sep 2, 2023, 11:04 Witold Gren @.***> wrote:

Unfortunately, my cameras still don't work after updating the add-on.

— Reply to this email directly, view it on GitHub https://github.com/fuatakgun/eufy_security/issues/896#issuecomment-1703770782, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABZ4APMJLT6VYO3MYQUQS4DXYLZDDANCNFSM6AAAAAA3YGASUU . You are receiving this because you commented.Message ID: @.***>

lbreggi commented 11 months ago

same here - even after update to 1.6.4. this is the error:

Error: <Task finished name='Task-3815' coro=<WebSocketClient._process_messages() done, defined at /config/custom_components/eufy_security/eufy_security_api/web_socket_client.py:62> result=None>

thanks!

witold-gren commented 11 months ago

same here - even after update to 1.6.4. this is the error:

Error: <Task finished name='Task-3815' coro=<WebSocketClient._process_messages() done, defined at /config/custom_components/eufy_security/eufy_security_api/web_socket_client.py:62> result=None>

thanks!

Just restart Home Assistant.. this is information that eufy plugin lost connection with add-on.

witold-gren commented 11 months ago

BTW. In my case.. I updated add-on to version 1.6.4. Then removed all configuration related with eufy, then I used HACS and again downloaded code and I restarted HA. Finally again I configured eufy plugin.. Unfortunately, it didn't help, the effect is the same as described above..

I also checked in mobile my account (which I use with HA) and even though I don't use 2FA on that one account everything worked..

DaveR2419 commented 11 months ago

1.6.4 is working for me.

lbreggi commented 11 months ago

same here - even after update to 1.6.4. this is the error: Error: <Task finished name='Task-3815' coro=<WebSocketClient._process_messages() done, defined at /config/custom_components/eufy_security/eufy_security_api/web_socket_client.py:62> result=None> thanks!

Just restart Home Assistant.. this is information that eufy plugin lost connection with add-on.

Thanks for the advise! sometimes restarting make it work again but most of times it not. this behavior started after the update. any other recommendation?

lbreggi commented 11 months ago

those are the errors that I'm getting:

{ stationSN: 'T8010N132152024A', message: { sequence: 10, commandType: 1145, nestedCommandType: undefined, channel: 5, acknowledged: true, retries: 0, returnCode: -133, data: <Buffer d1 00 00 0a 58 5a 59 48 79 04 90 00 00 00 01 00 05 02 00 00 55 95 c2 1d 82 50 48 35 89 d3 27 dc 58 25 bd e3 8b f6 33 44 c4 48 3b ad 65 52 4e e3 7f 4a ... 114 more bytes> } } 2023-09-11 18:59:24.306 WARN Result data for command not received { stationSN: 'T8010N132152024A', message: { sequence: 11, commandType: 1145, nestedCommandType: undefined, channel: 1, acknowledged: true, retries: 0, returnCode: -133, data: <Buffer d1 00 00 0b 58 5a 59 48 79 04 90 00 00 00 01 00 01 02 00 00 1a af d3 18 8b 4a a9 0e ad 5c f1 5a aa 5f 87 1c 8b f6 33 44 c4 48 3b ad 65 52 4e e3 7f 4a ... 114 more bytes> } } 2023-09-11 18:59:24.346 WARN Result data for command not received { stationSN: 'T8010N132152024A', message: { sequence: 12, commandType: 1145, nestedCommandType: undefined, channel: 2, acknowledged: true, retries: 0, returnCode: -133, data: <Buffer d1 00 00 0c 58 5a 59 48 79 04 90 00 00 00 01 00 02 02 00 00 ab ba c3 fb 37 eb c4 99 60 69 f8 5d c3 d8 de 05 8b f6 33 44 c4 48 3b ad 65 52 4e e3 7f 4a ... 114 more bytes> } } 2023-09-11 18:59:24.354 WARN Result data for command not received { stationSN: 'T8010N132152024A', message: { sequence: 13, commandType: 1145, nestedCommandType: undefined, channel: 3, acknowledged: true, retries: 0, returnCode: -133, data: <Buffer d1 00 00 0d 58 5a 59 48 79 04 90 00 00 00 01 00 03 02 00 00 25 5d e6 8e 8a 11 75 bf 26 9f 4e 87 3c dc 13 79 8b f6 33 44 c4 48 3b ad 65 52 4e e3 7f 4a ... 114 more bytes> }

witold-gren commented 11 months ago

Hey, on my case finally I found a problem. From some reason (currently I don't know why) part of my entities was disabled..

image image

I don't know what causes a large number of entities to be disabled

image

but after turning them on again, everything starts working normally

image

maybe this tip will help someone :)

witold-gren commented 11 months ago

PS. I found information that all this entities was disabled by integrations

image

@fuatakgun Do you have any suspicion of what might have happened? :)

fuatakgun commented 11 months ago

All debug entities should be disabled on initial setup but users can enable them if they are interested.

But control entities should be enabled by default.

This is needed to keep database size small as debug entities such as p2p queue is generating huge number of state changes to be recorded.

witold-gren commented 11 months ago

Thanks for the explanation, now I understand the problem.. although it seems to me that "Guard Mode" or "Alarm Control Panel" should be available always 😀https://github.com/fuatakgun/eufy_security/blob/master/custom_components/eufy_security/const.py#L144

PS. It will be nice add this information to README.md 😀that part of entities was disabled by design and the user can enable it.

fuatakgun commented 11 months ago

Please raise a PR if you think it is a useful sensor to move into the control section and to update readme accordingly

witold-gren commented 11 months ago

@fuatakgun Created small PR with information about diagnostic entities 😀 https://github.com/fuatakgun/eufy_security/pull/930