Uploaded image for project: 'Moodle'
  1. Moodle
  2. MDL-64013

Bootstrap loaded from CDN for privacy exports is fragile

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Duplicate
    • Icon: Minor Minor
    • None
    • 3.4.6, 3.5.3
    • Privacy
    • None
    • MOODLE_34_STABLE, MOODLE_35_STABLE

      As of MDL-62491, moodle_content_writer.php loads bootstrap's CSS file from a CDN.

      This is fragile for several reasons:

      • It requests the URL with a plain fopen(), without using the HTTP proxy if one is configured.
      • Failure of the request is not handled, so the process fails with an error if the CDN cannot be contacted.
      • The code is called from within unit tests, so the tests will fail if the CDN cannot be contacted.  I think its better to avoid connecting to external services in a unit test.

      I propose that we have a local copy of the CSS files in the codebase, and copy the appropriate one into the export rather than downloading it from the CDN.

            Unassigned Unassigned
            marxjohnson Mark Johnson
            Votes:
            1 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved:

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