-
Bug
-
Resolution: Fixed
-
Minor
-
3.4.4, 3.5.1, 3.6.4, 3.7, 3.8, 3.9
-
MySQL
-
MOODLE_34_STABLE, MOODLE_35_STABLE, MOODLE_36_STABLE, MOODLE_37_STABLE, MOODLE_38_STABLE, MOODLE_39_STABLE
-
MOODLE_38_STABLE, MOODLE_39_STABLE
-
MDL-63252-master -
-
0
-
International 4.0 - Sprint 2, International 4.0 - Sprint 3
Hi,
When we use tool "Site administration / Development / XMLDB editor / Check Defaults" , it returns false warnings with some integer values.
Sample :
- Table: question. Field: defaultmark, Expected '1' Actual '1.0000000'
- Table: question_answers. Field: fraction, Expected '0' Actual '0.0000000'
- Table: question_attempts. Field: maxfraction, Expected '1' Actual '1.0000000'
- Table: grade_items. Field: grademax, Expected '100' Actual '100.00000'
- .....
This problem is not present in an old version of Moodle (3.1.5)
After searching in source, I found a difference in file
$WWWROOT/admin/tool/xmldb/actions/check_defaults/check_defaults.class.php (line 97)
In Moodle 3.5 , the test is :
if ($physicaldefault !== $xmldbdefault) { |
In Moodle 3.1 it was:
if ($physicaldefault != $xmldbdefault) { |
I suppose that the problem comes from the test
" != " tests only the value , " !== " tests the value and type
I try to change " !== " to " != " in my Moodle 3.5 and get no warnings
Thanks a lot
- has a non-specific relationship to
-
MDL-59583 MariaDB 10.2.7 breaks dml unit tests
- Closed
- has been marked as being related by
-
MDL-70757 XMLDB editor false positive warning for NUMERIC type
- Closed
- is a regression caused by
-
MDL-59323 XMLDB: Check defaults does not work correctly with char fields
- Closed
- Testing discovered
-
MDL-69973 mariadb returns wrong defaults from RDBMS metadata (plus caching issue)
- Closed