Affects Version/s: 3.6.3, 3.7
Fix Version/s: 3.6
- Ensure that repository_url_testsuite phpunit passes using PHP 7.3. Can use ci.moodle.org facilities for that.
(note that there maybe other remaining failures if a full run is performed because there are some problems with both solr/redis and their PHP 7.3 status. At the effects of this issue, they are 100% ignorable).Ensure that repository_url_testsuite phpunit passes using PHP 7.3. Can use ci.moodle.org facilities for that. (note that there maybe other remaining failures if a full run is performed because there are some problems with both solr/redis and their PHP 7.3 status. At the effects of this issue, they are 100% ignorable).
Affected Branches:MOODLE_36_STABLE, MOODLE_37_STABLE
Pull from Repository:
Pull 3.6 Branch:
Pull 3.6 Diff URL:
Pull Master Branch:
Pull Master Diff URL:
PHP 7.3 moves from PCRE1 to PCRE2 engine. That comes with some new features, improvements, 99% backwards compatibility... and with a few incompatibility changes. Mainly:
- The "S" modifier has not effect anymore. (no impact)
- The "X" modified is now default on in PCRE2. (no impact)
- Better handling of unicode. (should be no impact too, haven't found cases out there).
- Slightly more strict about invalid patters (impact).
So, basically this is about to try to find in advance all the PCRE patterns breaking with the new engine and modify them. After having searched the net for docs and cases... the unique case I've been able to find, affecting lots of products... is this, let's call it:
A) The hyphen case : https://3v4l.org/tliEE
B) .... (add here if anybody is aware of more cases)
The approach I'm following to fix this is:
- Extract from code base all the candidate expressions matching the case (there will be false positives, no worries).
- Run a preg_match() with php71/72 using them:
- Those failing will be examined but discarded, 99% of them will be false positives.
- Pick those compiling ok and... only with them...
- Run the very same preg_match() with php73
- Those passing are ok, they are not problematic.
- Those failing will be the ones to examine closely. Hopefully not many.
So, working on it... ciao
Again: Haven't been able to find other problems apart from A) above. If anybody is aware of any... please share them here.