Warning when uploading a scorm over a previous with different item identifier in the manifest
Description
Testing Instructions
Create scorm and upload a package
Edit the scorm setting
The form should display as usually
upload another package that has a different item identifier
Click save
The form should display an error and a select field so you can decide to go forward or not
To go forward while knowing that some data could be lost, select 'yes' from the warning field
The scorm will be saved as usually.
Automated test results
Pre-check results
Workaround
Attachments
has a non-specific relationship to
Activity
Thanks @Johnny Tsheke - I have seen that model used in some places in moodle - show an error and then a 2nd submit will overwrite the error (like in advanced grading methods etc) - I suspect that has a higher chance of landing than your previous version but it may depend on the component leads/integrator who may need to consider if this meets our current UX guidelines.
My vote would be to say that while a better UX could be designed, Moodle HQ no longer puts effort into feature development on SCORM and this change includes (or will include) behat tests, and provides a good value to the end user, preventing accidental data loss and hopefully is good enough to land in the current form.
I haven't looked at the code, but when you've got that behat test in feel free to push through for Peer review, and hopefully someone will pick it up.
thanks!
Code verified against automated checks.
Checked https://moodle.atlassian.net/browse/MDL-81726#icft=MDL-81726 using repository: https://github.com/Tsheke/moodle
main (0 errors / 0 warnings) [branch: MDL-81726-master | CI Job]
Fails against automated checks.
Checked https://moodle.atlassian.net/browse/MDL-81726#icft=MDL-81726 using repository: https://github.com/Tsheke/moodle
main (1 errors / 0 warnings) [branch: MDL-81726-master | CI Job]
Hi @Dan Marsden ,
Thanks so much. I updated to avoid any UX change, Here is how it works now when an item identifier change is detected.
A warning message is display as an arror (see attached screen shot).
If user decide to continue (submit again without changing the package ), the package will be updated as usual. If they upload another package, another check is performed again.
Behat test is under development.
Thanks @Johnny Tsheke for supplying a patch!
I note the UX there is quite different from other Moodle pages and would probably get blocked by our UX team - what might be simpler is if on submission when a file like this is detected - you display a simple error message on the page (not the full form) with 2 options "continue and delete existing attempts" or "cancel" and return to the editing form.
Also - this will definitely need behat tests to cover the new functionality before we can get this in.
Details
Details
Priority
Components
Labels
Assignee
Reporter
Participants
Pull from Repository
Pull Main Branch
Clockify
Start / Stop
Clockify

https://docs.moodle.org/404/en/SCORM_FAQ#:~:text=for%20more%20information)-,SCORM%20results%20deleted%20after%20package%20update,package%20in%20Moodle%20is%20deleted.
SCORM results deleted after package update
When uploading a SCORM package over a previous one, if the item identifier in the manifest file is different to the one being overwritten then the tracking data for that SCORM package in Moodle is deleted.
It would be better to display a warning to let user knows that privious data will be lost. In the health field for instance, those data might be used as proof of required certification for some practice. loosing data leads may lead to restriction on using some equipments and ended impact people health. For example, a nurse who completed a course could not use an equipment or a software because the regulation requires to complete the course before using it.
We want to add a warning so the teacher can decide to go forward or not before loosing data.