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

Consider modernising the mysql (and children) native database drivers

XMLWordPrintable

    • Icon: Improvement Improvement
    • Resolution: Unresolved
    • Icon: Minor Minor
    • None
    • Future Dev
    • Database SQL/XMLDB
    • None

      The mysql native driver we use on top of the mysql php extension works great, but it may get some nice improvements.

      One of them is about to stop using MYSQLI_REPORT_OFF, that is a mode that makes all the driver functions to just return null/false instead of throwing better exceptions/errors.

      And, instead, enable MYSQLI_REPORT_ERROR|MYSQLI_REPORT_STRICT, that is, in fact, the default since PHP 8.1 (see MDL-75760, where we had to force the old mode).

      With the new mode, proper exceptions and errors are returned, just our native driver is not ready to receive them.

      So this issue is about to consider updating the driver (and its children) to support those exceptions better (try...catch...) instead of relying on returned values.

      No change in functionality should happen (all the changes must remain internal to the native driver), but surely it will be more robust if we apply those new error handling techniques.

      Ciao

            Unassigned Unassigned
            stronk7 Eloy Lafuente (stronk7)
            Votes:
            1 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:

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