ep1cman / unifi-protect-backup

Python tool to backup unifi event clips in realtime
MIT License
576 stars 25 forks source link

Filename format changed in v0.10.0 #112

Closed kitleyn closed 8 months ago

kitleyn commented 8 months ago

Description

Since upgrading from v0.9.5 to v0.10.0 (many thanks for the fixes btw) the file name format, specifically relating to {detection_type}, seems to have changed. Is this intentional?

Old format: /unifi-protect/Front Door/2023-10-30/2023-10-30T11-56-21 smartDetectZone (vehicle).mp4

New format: /unifi-protect/Front Door/2023-11-01/2023-11-01T12-48-33 EventType.SMART_DETECT (vehicle).mp4

ep1cman commented 8 months ago

Definitely not intentional!

kitleyn commented 8 months ago

In case it helps, I also see the same change in the logs against the 'Type' entry on the downloader.

2023-11-01 14:06:14 [ DEBUG ] unifi_protect_backup.downloader : [65425a3101280003e40174cc] Type: EventType.SMART_DETECT (vehicle)

I reverted to v0.9.5 and confirmed that the filename format went back to the original.

ep1cman commented 8 months ago

Should now be fixed once the 0.10.1 release gets built. Looks like something changed with how python enums are turned into strings.