Reviewed & tested by the community
Project:
Opigno SCORM
Version:
3.0.3
Component:
Code
Priority:
Major
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
23 May 2022 at 19:59 UTC
Updated:
16 Jan 2025 at 11:30 UTC
Jump to comment: Most recent, Most recent file
Comments
Comment #2
cornifex commentedPatch adds the library to the project's composer.json file.
Comment #3
Zuiev commentedHey cornifex, thanks for the patch. Unfortunatelly it doesn't work for me and I'm still getting the error.
Thanks.
Comment #4
saurabh-2k17 commentedHey @Zuiev
You can directly require the dependency like
composer require opis/json-schemaThanks
Comment #7
liam mcdermott commentedI created an MR that adds the dependency, and tested it.
This would be due to patches being applied after composer has resolved dependencies, because of this, adding new dependencies in patches doesn't work.
Instead, if you add this to your project's `composer.json` as the first item under `repositories`:
And put this under your `composer.json`'s `require` section:
And run `composer update`, it should fix the issue. Or you can add it as a direct dependency, like saurabh-2k17 suggested, but that won't help test the fix for this issue. If the above works for anyone else, please come and mark this as 'Reviewed and tested by the community'.
To reproduce this issue, install Opigno SCORM without any of the other Opigno modules, add a SCORM field to some content type, then add content of that type and upload a SCORM file, load that content in the browser, then open the browser console and interact with the loaded SCORM content. When moving between steps this error should be shown in the console (it's a JS http request).
Comment #8
kurttrowbridgeHi! I followed the instructions in #7 while also excluding this module from the standard Drupal repository (see snippet below), and that installed the dependencies successfully and fixed the errors. Marking RTBC. Thanks!
Comment #9
jepster_I do also confirm that the changes from the MR do work for my project.
You must be careful, that you really install the ^2.3 version and not just the latest version. Because the latest version of opis/json-schema cannot be auto-loaded via composer.