openfun / marsha

:clapper: An opensource LTI Learning Content Management System (LCMS)
MIT License
107 stars 24 forks source link

Deleted resource should not generate an error 500 when access in LTI #2399

Closed lunika closed 11 months ago

lunika commented 1 year ago

Bug Report

Problematic Behavior

When a resource is deleted in the site but still used in LTI, everytime this resource is access in LTI marsha generates an error 500 because it tries to create a resource in the database the the resource with this id exists and is soft deleted.

Expected behavior/code

The already existing id error should be catch and a response should be return informing that the resource is deleted.

Steps to Reproduce

  1. Create a resource in LTI
  2. Claim the playlist to be allowed to manage it on the site
  3. Delete the resource on the site
  4. Relaunch the LTI page.