-
Bug
-
Resolution: Duplicate
-
Minor
-
None
-
3.11.3
-
None
-
MOODLE_311_STABLE
I am confident this is not a database activity issue but it is an issue affecting each module. I tested it against database but I feel it is a common behaviour of each module.
Follow this procedure to get evidence of the notices.
cd /your/web/folder
php -v
PHP 7.4.2 (cli) (built: Feb 17 2020 12:56:02) ( NTS )
Copyright (c) The PHP Group
Zend Engine v3.4.0, Copyright (c) Zend Technologies
with Zend OPcache v7.4.2, Copyright (c), by Zend Technologies
with Xdebug v2.9.2, Copyright (c) 2002-2020, by Derick Rethans
git clone https://github.com/moodle/moodle.git stable
cd stable
git br MOODLE_311_STABLE origin/MOODLE_311_STABLE --track
git co MOODLE_311_STABLE
php admin/cli/install.php
follow instructions until the installation is over.
Set:
$CFG->debug = E_ALL | E_STRICT;
$CFG->debugdisplay = true;
create a course
create an instance of database
add a field to database
add the default template to view database entries
Visit database "Edit settings" page
Go to "Activity completion" section
Set "Show activity as complete when conditions are met"
Set "Count of entries" to "1"
Push the "Save and display" button.
In database activity page submit an entry
Visit database "Edit settings" page once again
Go to "Activity completion" section
You must see the blue "Unlock completion options" button
Do not push it.
Push the "Save and return to course" button to return to database activity.
You should get three notices:
( ! ) Notice: Trying to access array offset on value of type null in /Applications/MAMP/htdocs/stable/lib/formslib.php on line 2253
Call Stack
- Time Memory Function Location
1 0.0002 386896 {main}( ) .../modedit.php:0
2 0.3340 7919024 mod_data_mod_form->get_data( ) .../modedit.php:164
3 0.3340 7919024 mod_data_mod_form->get_data( ) .../moodleform_mod.php:1279
4 0.3340 7919024 mod_data_mod_form->is_validated( ) .../formslib.php:699
5 0.3359 7921656 mod_data_mod_form->validate_defined_fields( ) .../formslib.php:589
6 0.3364 7921856 MoodleQuickForm->exportValues( ) .../formslib.php:652
( ! ) Notice: Trying to access array offset on value of type null in /Applications/MAMP/htdocs/stable/lib/formslib.php on line 2253
Call Stack
- Time Memory Function Location
1 0.0002 386896 {main}( ) .../modedit.php:0
2 0.3340 7919024 mod_data_mod_form->get_data( ) .../modedit.php:164
3 0.3340 7919024 mod_data_mod_form->get_data( ) .../moodleform_mod.php:1279
4 0.3478 8015128 MoodleQuickForm->exportValues( ) .../formslib.php:700
( ! ) Notice: Trying to access array offset on value of type null in /Applications/MAMP/htdocs/stable/lib/formslib.php on line 2253
Call Stack
- Time Memory Function Location
1 0.0002 386896 {main}( ) .../modedit.php:0
2 0.3517 8018224 update_moduleinfo( ) .../modedit.php:166
3 0.3517 8018264 mod_data_mod_form->get_data( ) .../modlib.php:522
4 0.3517 8018264 mod_data_mod_form->get_data( ) .../moodleform_mod.php:1279
5 0.3517 8018264 MoodleQuickForm->exportValues( ) .../formslib.php:700
- duplicates
-
MDL-72654 Notice when saving an activity with activated completion conditions
-
- Closed
-