Skip to content

Conversation

@Tarterman
Copy link
Contributor

Description

The current way -IncludeRetentionInfo performs is that it just finds the oldest video and checks if it is older than or equal to the configured retention. That works fine, except when evidence locks are in use. If there is an evidence lock on video that is older than the configured retention, then the retention that is returned doesn't tell you if there is even any non-evidenced locked video in the retention window.

This change checks to see if the camera has evidence locks. If it does, it uses a method to find the closest GOP to the configured retention time and uses that start time to check if

Related Issue

#160

Motivation and Context

This makes it so the actual retention mentioned in the output excludes evidence locked video that might exist after the configured retention. That way the user gets a more accurate value.

How Has This Been Tested?

Tested it against the current function to make sure nothing else was affected and to make sure the values were accurate.

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)

Checklist:

  • My code follows the code style of this project.
  • My change requires a change to the documentation.
  • I have updated the documentation accordingly.
  • I have read the CONTRIBUTING document.
  • I have added tests to cover my changes.
  • All new and existing tests passed.

@github-actions
Copy link
Contributor

Test Results

5 048 tests   5 046 ✅  1m 44s ⏱️
1 586 suites      2 💤
    1 files        0 ❌

Results for commit eee2720.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant