Selecting checkbox fails: checklist never completes refresh

Created on 4 June 2025, about 1 month ago

Problem/Motivation

I am trying to set up some lessons using this module. One part of this has a checklist of items the student is supposed to mark when completed. But in testing, I find that if I check a checkbox, the page just sits there with a loading animation over the top of the checklist. That never stops.

Steps to reproduce

  1. Create a lesson.
  2. Add a checklist.
  3. Save it.
  4. Display the lesson.
  5. Check one of the checkboxes.

Result:

The console displays some errors, possibly relevant:

           GET http://localhost/anu_lms/lesson/checklist?_format=json&checklist_paragraph_id=71 404 (Not Found)
(anonymous) @ js_40EG4soarlsTrgEpa39dqYNtJUnOsetUvsmsu2WiCm0.js?scope=footer&delta=0&language=en&theme=essential1_1&include=eJx9jusNwzAIhBdy4xk6iYUTGqFigzBJO34fipuolfqL47vjBNQlcWmRsTWpIdOclBRjFyGLeHMDjR-V1DBRJT-YKior2oG4CDtpGKU63n0BjpMtCjzs5MRUr-1_5NWTwZ4hw27D6LTi-zpsfuy5r33ANoLieSpUww3zRazEbQ4TAcvccdqf_yEPGup1QQ:28

This one is repeated many times.

Proposed resolution

Remaining tasks

User interface changes

API changes

Data model changes

🐛 Bug report
Status

Active

Version

2.11

Component

Code

Created by

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

  • Issue created by @leeksoup
  • So it turns out that the problem is caused by the local dev site running from a sub-directory. Even though I have set the RewriteBase to point to that directory, in some situations it fails to find resource because it is using the wrong paths. In this case, it should be:
    localhost/XYZ/web/modules/contrib/anu_lms/... and not localhost/anu_lms/...

    I don't know why the modules/contrib also is missing from the path on the dev site. Maybe it doesn't find the site root so it can't resolve the rest of the path either??

    Whatever the reasons, this does work on the hosted site.

Production build 0.71.5 2024