adaptlearning / adapt_authoring

A server-based user interface for authoring eLearning courses using the Adapt framework.
https://www.adaptlearning.org/
GNU General Public License v3.0
513 stars 278 forks source link

course import error: UnhandledPromiseRejectionWarning: TypeError: Cannot read property 'split' of null #2580

Open eclass4learning opened 2 years ago

eclass4learning commented 2 years ago

Expected Behaviour

for the course to be properly imported

Actual Behaviour

adapt throws an UnhandledPromiseRejectionWarning adapt.log

Steps to Reproduce

export course from another server, then import course into another server.

Versions

Screenshot_2021-12-01_09-38-51

taylortom commented 2 years ago

Hi @eclass4learning, are you able to share the course you were trying to import? If not, it would be very helpful to get some more detailed information about the error - usually there's a stack trace which gives you more details about where the error occurred.

simondate commented 2 years ago

I recently had this with some courses I was trying to upload. After some playing around I realised the content had some images with the .jfif format. I replaced these with standard images and the error went away and I was able to upload.

@taylortom do you think we should prevent non-standard file formats being uploaded to prevent this sort of error occouring?

taylortom commented 2 years ago

@simondate this isn't something that we've planned to fix in the legacy codebase, but is in v1.0.0 already 😀