-
Bug
-
Resolution: Fixed
-
Major
-
4.0.4, 4.1, 4.2
When you create a preconfigured LTI 1.3 tool in course context, do a backup of this activity and restore it in another course of the same instance (or restore it twice in different courses of another instance), restore process breaks with dml_exception ("Duplicate entry 'RKWPPLtg4mn9ppC' for key 'mdl_ltitype_cli_uix' ").
This happens because restore keeps the original clientid (which has to be unique) when it inserts the new ltitype that is attached to the course.
Steps to reproduce:
- Create a course
- Create an activity of type "External Tool" and add a preconfigured tool using LTI 1.3 for this activity.
- Do a backup of this activity
- Restore the backup to another course - it will fail.
Care: This issue affects all preconfigured tools which have been configured at least ONCE with LTI 1.3, even if the LTI version is being changed back to LTI 1.0/1.1 afterwards, because the client id will be kept anyway.