Islandora-Labs / islandora_solution_pack_oralhistories

Adds all required Fedora objects to allow users to ingest and retrieve Oral Histories (video/audio) files through the Islandora interface
GNU General Public License v3.0
13 stars 23 forks source link

islandora_oralhistories_media_uploaded_type race condition #119

Closed willtp87 closed 6 years ago

willtp87 commented 6 years ago

The use of the Drupal variable islandora_oralhistories_media_uploaded_type creates a race condition. When an object being ingested sets the variable and before the variable's use another object of a different type is ingested and sets the variable it will not be accurate when accessed to create the derivatives of the first object. I am planning on submitting a pull request that removes this variable and changes derivatives to rely on the OBJ's mime directly. This will also fix issues with re-running derivatives, command line ingests and OBJ replacement where they may not reflect the current object because the variable is only set in the upload form submit handler. Please let me know if this solution is not acceptable.

MarcusBarnes commented 6 years ago

Thank you @willtp87 I'm looking forward to reviewing your pull-request.

MarcusBarnes commented 6 years ago

Thank you @willtp87 for catching this behaviour.