-
Task
-
Resolution: Done
-
Major
-
4.1
-
None
-
MOODLE_401_STABLE
-
MOODLE_401_STABLE
Preparations
This is about to inspect apache logs for complete behat runs and fix as many notices / problems are shown there. Aggregating information from all supported themes.
Used this regexp against goutte and chrome webserver logs:
ag -v 'POST|GET|OPTIONS|\] (checking plan|(saving|calculating|loading|setting) controller|(applying|loading|instantiating) (backup|restore|plan)|(activity|section) skipped|setting file inclusion|processing file aliases|Unknown setting: (questionbank|overwrite_conf|course_shortname|course_fullname|course_startdate))|Failed Login: ' aggregated.txt > results.txt
|
(where aggregated.txt is the union of goutte and chrome web server logs of all core themes)
Trick: When it's difficult to find which exact behat test is causing the problem, it's useful to run the tests with the --pretty command, getting the date prepended, that way later can match them with the dates in apache error logs. To do so just add the following to your behat run command:
vendor/bin/behat ...... --format pretty --no-colors | awk '{ print strftime("%Y-%m-%d %H:%M:%S"), $0; fflush(); }'
|
You can see the actual results @ results.txt
Trick: Always look to previous release issue to verify if the error already was detected there and considered ok.
Summary:
Problem A: Cannot find session record. It happens 2 times.
Happens in scenario "As a student, request deletion of account and data"
84489:[Tue Nov 15 07:49:13.754595 2022] [php:notice] [pid 2614] [client 172.28.0.6:54298] Cannot find session record 7f9cc8dd1979da40214a1b80be3ae843 for user 103000, creating new session., referer: http://webserver131d771ed741fc3b/behatrun3/user/profile.php
Confirmed that it's testing exactly that the session has expired (see prev. release). So 100% ignorable.
Problem B: User id 'xxxxxx' already has a grade. It happens 2 times.
MDL-68961
Happens with scenario "Delete and restore a quiz with user data.
185918:[Tue Nov 15 09:22:41.372725 2022] [php:notice] [pid 5581] [client 172.28.0.5:39084] User id '106001' already has a grade entry for grade item id '169000', referer: http://webserver131d771ed741fc3b/behatrun2/admin/tool/recyclebin/index.php?contextid=107002
Confirmed that it's trying to recreate already existing course grade (see MDL-68961 and prev. release). So 100% ignorable.
Problem C & D from 4.0 inspection (MDL-72815) are not happening anymore with 4.1.
Added a note to MDL-68996
Problem E: Debugging: String [filterrowlegend,core_user] is deprecated. It happens 26 times.
MDL-76388
2162:[Tue Nov 15 06:02:52.137271 2022] [php:notice] [pid 508] [client 172.28.0.6:33416] Debugging: String [filterrowlegend,core_user] is deprecated. Either you should no longer be using that string, or the string has been incorrectly deprecated, in which case you should report this as a bug. Please refer to https://docs.moodle.org/dev/String_deprecation in
- line 397 of /lib/classes/string_manager_standard.php: call to debugging()
- line 117 of /lib/external/externallib.php: call to core_string_manager_standard->get_string()
- line 261 of /lib/externallib.php: call to core_external::get_string()
- line 81 of /lib/ajax/service.php: call to external_api::call_external_function()
- line 33 of /lib/ajax/service-nologin.php: call to require_once()
, referer: http://webserver131d771ed741fc3b/behatrun3/user/index.php?id=100000
Problem F: PHP8 warning in theme_config->editor_css_files(). It happens 12 times.
MDL-76389
160656:[Tue Nov 15 09:02:05.331079 2022] [php:notice] [pid 4853] [client 172.28.0.6:33522] Default exception handler: Exception - Warning: foreach() argument must be of type array|object, null given in [dirroot]/lib/outputlib.php on line 968 Debug:
Error code: generalexceptionmessage
- line 157 of /lib/behat/lib.php: Exception thrown
- line 968 of /lib/outputlib.php: call to behat_error_handler()
- line 1331 of /lib/outputlib.php: call to theme_config->editor_css_files()
- line 129 of /theme/styles.php: call to theme_config->get_css_content_editor()
, referer: http://webserver131d771ed741fc3b/behatrun3/course/modedit.php?add=data&type=&course=100000§ion=1&return=0&sr=0
Problem G: Using deprecated magic setters/getters in tool_lp\external::data_for_competency_summary(). It hapeens 8 times.
MDL-76390
154782:[Tue Nov 15 08:57:36.330964 2022] [php:notice] [pid 4607] [client 172.28.0.4:35302] Debugging: Use of magic setters and getters is deprecated. Use get() and set(). in
- line 57 of /competency/classes/persistent.php: call to debugging()
- line 281 of /admin/tool/lp/classes/external.php: call to core_competency
persistent->__call()- line 261 of /lib/externallib.php: call to tool_lp
external::data_for_competency_summary()- line 81 of /lib/ajax/service.php: call to external_api::call_external_function()
, referer: http://webserver131d771ed741fc3b/behatrun1/admin/tool/lp/user_competency_in_course.php?courseid=100000&competencyid=235001&userid=104000
- has a clone
-
MDL-77758 Fix problems reported in apache logs before 4.2 release
- Closed
- has a non-specific relationship to
-
MDL-68996 Behat webserver logs: Course or activity not accessible (autosave-ajax)
- Closed
-
MDL-72509 Move the participants filter UI from within core_user to a re-usable API
- Closed
- has been marked as being related by
-
MDL-73019 Verify that the apache logs are clean of PHP 8.1 notices/warnings/errors
- Closed
- is a clone of
-
MDL-72815 Fix problems reported in apache logs before 4.0 release
- Closed