Uploaded image for project: 'Moodle Community Sites'
  1. Moodle Community Sites
  2. MDLSITE-7329

In Moodle plugin code prechecks, Mustache "info" messages are treated as warnings

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: Low Low
    • moodle.org/plugins
    • None

      In the Moodle plugin code prechecks, Mustache lint seems to treat HTML validation info messages as warnings.

      I have run into this recently, while checking my course format plugin. I guess there's been a recent change to the HTML validator that's caused it? A Mustache file failed validation because some included Moodle Mustache files closed HTML single tags with /> instead of just >. I got the "info" message "Trailing slash on void elements has no effect and interacts badly with unquoted attribute values." As far as I can tell, this message is only ever given when there is no actual problem, and if there is an actual problem with a trailing /, I think another, non-info message will likely be given.

      I don't think it's necessary to treat "info" messages as warnings, and I suspect it will now cause most course format plugins to fail validation in a way that's beyond the author's control. (Not sure about other plugin types.)

      (I've also reported essentially the same issue with the Moodle local CI plugin https://github.com/moodlehq/moodle-local_ci/pull/274 . I had thought the Moodle plugin code prechecks might have used this, but now I suspect not?)

            Unassigned Unassigned
            james-cnz James E. Calder
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:

                Error rendering 'clockify-timesheets-time-tracking-reports:timer-sidebar'. Please contact your Jira administrators.