-
Bug
-
Resolution: Fixed
-
Major
-
4.5
-
MOODLE_405_STABLE
-
MOODLE_405_STABLE
-
MDL-83085-main -
-
2
-
Team Hedgehog 2024 Sprint 3.2, Team Hedgehog 2024 Sprint 3.3
Error
Exception - Unknown named parameter $read_timeout
Debug info:
Error code: generalexceptionmessage
Stack trace: * line 292 of /lib/classes/session/redis.php: Error thrown
- line 149 of /lib/classes/session/manager.php: call to core\session\redis->init()
- line 136 of /lib/classes/session/manager.php: call to core\session\manager::start_session()
- line 905 of /lib/setup.php: call to core\session\manager::start()
- line 51 of /config.php: call to require_once()
- line 37 of /my/index.php: call to require_once()
====================
I tested with different PHP and PHPRedis versions.
PHP | PHPRedis | Result |
---|---|---|
8.3 | 5.3.5 | Error |
8.2 | 6.0.2 | Success |
8.1 | 6.0.2 | Success |
FYI, the problem is not only the read_timeout but also with the context parameter.
I dug into the PHPRedis repository to find the root cause. It turns out that before version 6.0.0, for example, 5.3.5, PHPRedis only exposes some of the params that can be used as named params. Check the code here.
Since version 6.0.0, PHPRedis has used redis.stub.php to expose parameters on each functions.
- Discovered while testing
-
MDLQA-19188 CLONE - redis session handler can be used to manage users sessions
- Passed
- is a regression caused by
-
MDL-66151 Performance: Allow session stores to fully manage the session
- Closed