-
Bug
-
Resolution: Fixed
-
Minor
-
3.11.3
-
MOODLE_311_STABLE
-
MOODLE_311_STABLE
-
MDL-72670-master -
The purpose of the $CFG->enable_read_only_sessions_debug is to produce identical error messages to $CFG->enable_read_only_sessions, without enabling read only sessions. The idea being to turn on enable_read_only_sessions_debug on a large prod site, identify issues, fix them, and build some confidence that read only sessions can safely be enabled.
To reproduce simply add $CFG->enable_read_only_sessions_debug to config.php and create a test script:
<?php
|
|
require_once('config.php'); |
|
global $SESSION; |
|
$SESSION->myvar = 'asdf'; |
Save, tail your error log and then load the script. Nothing will show in the error log. Now modify the script, setting the value of $SESSION->myvar to 'asdfasdf'. Save and refresh, you will see an error in the log. This is a false positive, as the error should only trigger when when the script defines READ_ONLY_SESSION as true.