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

Items with "thumbsOnly" option don't display properly in the generated report #1409

Closed
wladimirleite opened this issue Oct 27, 2022 · 3 comments · Fixed by #1412
Closed

Items with "thumbsOnly" option don't display properly in the generated report #1409

wladimirleite opened this issue Oct 27, 2022 · 3 comments · Fixed by #1412
Assignees
Labels

Comments

@wladimirleite
Copy link
Member

Description

When the option "thumbsOnly" is used for one or more bookmarks in the report generation, the items won't display properly when the report is open - Metadata and Text views are empty.
This is a somewhat critical issue, as if you use "thumbsOnly", it is important to have access to item properties, through metadata viewer.

Versions

I got this issue working in a real case, using 4.0.6, but I believe it affects all versions >= 4.0.0, including master. It may affect 3.18.x, but I didn’t check it.

Reproduce

Process 2 videos, create 2 bookmarks (one with each video) and then generate a report, using thumbsOnly for one of the bookmarks.
When the report is opened, the "preview" viewer works (showing videos frame mosaic), but the metadata and text viewers do not.

Cause

Debugging the issue, it seems that items with thumbs only have mediaType = null, which prevents Metadata viewer from working.

if (item.getMediaType() != null) {

The mediaType is cleared here:

@wladimirleite
Copy link
Member Author

@lfcnassif, I found out that removing the last line I mentioned (evidence.setMediaType(null);) fix the issue, but I am not sure what side effects that may cause, so I would like that you check this problem in more detail, when you got some time.

@lfcnassif
Copy link
Member

Hi @tc-wleite. If I remember, mediaType is reset to force mediaType detection of viewFiles to redirect them to the right viewer, maybe that is not needed anymore after your Viewers refactoring. The MetadadaViewer should work for thumbsOnly files. Not sure about the TextViewer, since they won't have any content, perhaps just displaying metadata is an option, but may confuse users...

@lfcnassif
Copy link
Member

I also didn't remember the full purpose of the last part of the if clause just above the resetting line...

@wladimirleite wladimirleite self-assigned this Oct 28, 2022
lfcnassif added a commit that referenced this issue Oct 28, 2022
@lfcnassif lfcnassif changed the title Items with "thumbsOnly" option, doesn't display properly in the generated report. Items with "thumbsOnly" option don't display properly in the generated report Dec 20, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants