Opencast-Moodle / moodle-block_opencast

Block to manage Opencast publications in moodle
21 stars 27 forks source link

Unexpected behavior by visibility change #371

Closed alina-kiz closed 2 months ago

alina-kiz commented 3 months ago

Hi, we noticed unexpected behavior after the visibility change. When we do an import of hidden video, the video will appear in the LTI series activity, but the video will disappear from the list after few minutes in the Opencast block. All rights on the opencast site are revoked. After research in task process_duplicated_event_visibility_change.php, we came across a condition where the brackets are not there. https://github.com/Opencast-Moodle/moodle-block_opencast/blob/a2416a1d1aee8536cf6ecba7189acd6083b6c4b3/classes/task/process_duplicated_event_visibility_change.php#L116

With brackets, the video is still displayed and editable on Block Opencast.

Best regards Alina Antonova

ferishili commented 3 months ago

Technical Description:

The issue happens upon updating the visibility for hidden duplicated videos, in which currently non permanent and permanent acl roles both get empty arrays just because the related functions (get_permanent_acl_rules_for_status > get_acl_rules_for_status) do not make any difference for hidden videos if it is permanent roles and returns empty array, which is a main behavior problem IMHO. That is why hidden duplicated videos always get empty array for their acl roles (permanent & non-permanent) and by updating the event acls in Opencast passing empty array, it therefore removes all acls of that event.