fuatakgun / eufy_security

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

Enable versioning for releases #110

Closed nkm8 closed 2 years ago

nkm8 commented 2 years ago

Is your feature request related to a problem? Please describe. I updated both the integration and the addon to the newest version, but encountered a bug in the ws package that breaks everything. I want to do a partial backup restore to get the old version of the addon. However, I don't have a way to uninstall/reinstall the integration at the specific version/commit I need.

Describe the solution you'd like I propose adding some meaningful git tags that either match the version of the ws module or at least make it obvious which versions of the integration are compatible with which versions of the addon.

Describe alternatives you've considered I'm open to suggestions - besides forking the integration repo and doing this myself, I can't think of any other workarounds.

Additional context N/A

fuatakgun commented 2 years ago

i should stop acting lazy and publish integration with revisions, rather than commit id, that would solve it.

What is main problem with add-on?

nkm8 commented 2 years ago

@fuatakgun I think this issue matches my error: https://github.com/bropat/eufy-security-ws/issues/44

2021-11-15 00:00:35.779  INFO Eufy Security server listening on port 3000 
2021-11-15 00:00:36.508  ERROR Stations - Generic Error: 
 TypeError  Cannot read property 'length' of null
error stack:
• session.ts:1546 updateRawStation
    node_modules/eufy-security-client/src/p2p/session.ts:1546:37
• session.ts:98 P2PClientProtocol
    node_modules/eufy-security-client/src/p2p/session.ts:98:14
• station.ts:49 Station
    node_modules/eufy-security-client/src/http/station.ts:49:27
• eufysecurity.ts:329 handleHubs
    node_modules/eufy-security-client/src/eufysecurity.ts:329:33
• eufysecurity.ts:130 <anonymous>
    node_modules/eufy-security-client/src/eufysecurity.ts:130:50
• events.js:400 emit
    events.js:400:28
• api.ts:297 updateDeviceInfo
    node_modules/eufy-security-client/src/http/api.ts:297:30
• eufysecurity.ts:453 refreshCloudData
    node_modules/eufy-security-client/src/eufysecurity.ts:453:9
2021-11-15 00:00:37.144  INFO Push notification connection successfully established 
fuatakgun commented 2 years ago

Do you need rtsp or p2p support?

For p2p, you can just downgrade add-on, for rtsp you need to downgrade the integration too

nkm8 commented 2 years ago

Just p2p, my doorbell doesn't support rtsp, so I'll try downgrading the addon and will report back.

fuatakgun commented 2 years ago

As far as i know, there is no official way of downgrading any add-on, you should remove new docker image and install old one and restart add-on.

If you know other way around, let me know

nkm8 commented 2 years ago

I can confirm that rolling the addon back to the 0.3.3 release fixed the integration for p2p.

If you have a supervisor backup handy, the easiest way I know to rollback an addon is to do a partial restore and only select the addon you want to rollback - worked like a charm after a server restart.

fuatakgun commented 2 years ago

happy to hear your issue was mitigated with rollback. let's wait a resolution from @bropat

nkm8 commented 2 years ago

I can confirm that my addon failure was fixed by upgrading your addon to the 0.5.3 release. However, I think the premise of the issue is still valid, so I'll leave it open.

fuatakgun commented 2 years ago

Makes sense, versioning should be there

fuatakgun commented 2 years ago

@cdnninja can we assume this will be fixed after your changes?

cdnninja commented 2 years ago

If the action is enabled yes. I saw you had the action disabled previously.

fuatakgun commented 2 years ago

thanks to @cdnninja , this is resolved :clap::clap::clap::clap:

cdnninja commented 2 years ago

Two releases will occur per week going forward. One mid week one on weekends. This will allow easy role back of the integration portion only.