Skip to content
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

Bugfix for #252, don't attempt to read video file if invalid or 0 frames long #275

Merged
merged 1 commit into from
Jun 11, 2024

Conversation

Loran425
Copy link
Collaborator

Raise error if video file has 0 frames or is in valid.
video.get(cv2.CAP_PROP_FRAME_COUNT) returns 0 or -1

An addition change could be implemented by calling video.setExceptionMode(True) which would raise cv2 errors if other issues arise later.

Fixes #252

video.get(cv2.CAP_PROP_FRAME_COUNT) returns 0 or -1
@CyanVoxel CyanVoxel self-assigned this Jun 11, 2024
@CyanVoxel CyanVoxel added this to the Alpha 9.3.1 milestone Jun 11, 2024
@CyanVoxel CyanVoxel added the Type: Bug Something isn't working as intended label Jun 11, 2024
@CyanVoxel CyanVoxel merged commit e375166 into TagStudioDev:main Jun 11, 2024
3 checks passed
seakrueger pushed a commit to seakrueger/TagStudio that referenced this pull request Jun 17, 2024
)

video.get(cv2.CAP_PROP_FRAME_COUNT) returns 0 or -1
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Type: Bug Something isn't working as intended
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[BUG] Tagstudio crashes when clicking on a video that has no frames
2 participants