4737 Commits

Author SHA1 Message Date
Huong Nguyen
e25bcf9ede
Merge branch 'MDL-82946-401' of https://github.com/lameze/moodle into MOODLE_401_STABLE 2024-12-04 09:40:19 +07:00
Angelia Dela Cruz
311adf5f6f MDL-82946 qbank: Behat coverage for questions bulk actions 2024-12-03 10:44:28 +08:00
Andrew Nicols
76d24aed1e
MDL-81521 mod_quiz: Fix attempt walkthrough tests 2024-11-19 09:30:51 +08:00
Andrew Nicols
3d51aed3e2
MDL-81521 core: Update all possibly data providers to be static
Note: Some data providers could not be automatically be converted to
being static. These will be handled in a separate issue.
2024-11-19 09:30:51 +08:00
Simey Lameze
1ce15ab9b1 MDL-63399 behat: update existing tests to use the better download steps
Co-authored-by: Tim Hunt <T.J.Hunt@open.ac.uk>
2024-09-06 12:19:56 +08:00
Huong Nguyen
eb1c1e79a1
MDL-82798 qtype_ddmarker: Fix Behat failure 2024-08-15 09:17:41 +07:00
Michael Hawkins
0f03ac03b5
MDL-82576 qtype_calculated: Improve formula regexes 2024-08-08 11:12:28 +07:00
Paul Holden
aa7f8f9e09
MDL-82596 behat: switch manual private files upload to generator. 2024-07-28 19:29:54 +01:00
Jun Pataleta
c12d07d9d4
Merge branch 'MDL-82373-401' of https://github.com/andrewnicols/moodle into MOODLE_401_STABLE 2024-07-25 11:30:52 +08:00
Andrew Nicols
07bfca9041
MDL-82373 question: Make window larger in behat tests
I would suggest that this is a stop gap to solve some failing tests. We
really need to look at whether we can improve the usability of this
interface on smaller displays as a longer-term fix.
2024-07-17 14:45:22 +08:00
Paul Holden
1a7ec4cf3d
MDL-79717 phpunit: ensure unique data provider keys in tests.
Duplicate data provider keys were overwriting and/or duplicating
one another, leading to some cases being skipped.

Other "duplicate array key" errors were picked up by `phpcs` in
this dragnet across all tests, which have also been fixed.
2024-07-10 14:09:00 +01:00
Eloy Lafuente (stronk7)
ff263b6dbc
MDL-82148 phpunit: Remove all cases of multiple @coversDefaultClass
Only one by class is allowed (to be used as shortcut exclusively).
2024-06-14 16:05:48 +02:00
Simey Lameze
025065daf5 MDL-80589 behat: fixes and improvements to new tests 2024-05-02 13:34:16 +08:00
Angelia Dela Cruz
49be0febdc MDL-80589 qtype_numerical: Behat to add, edit, preview numeric question 2024-05-02 13:34:16 +08:00
Andrew Nicols
d8d560b7fe
MDL-79003 js: Use our own jsdoc wrapper
grunt-jsdoc is abandoned and only works with an older version of jsdoc.

This is a very simple wrapper around jsdoc itself.

This commit also includes a fix for broken docs.
2024-01-30 14:07:06 +08:00
Huong Nguyen
2302bb7e2b Merge branch 'MDL-77136-401' of https://github.com/lucaboesch/moodle into MOODLE_401_STABLE 2023-12-07 08:37:07 +07:00
Jun Pataleta
467a28d921
Merge branch 'MDL-80127_401' of https://github.com/timhunt/moodle into MOODLE_401_STABLE 2023-12-06 22:11:56 +08:00
Luca Bösch
69d235426a MDL-77136 qtype_randomsamatch: Newest versions for shortanswer questions 2023-12-06 14:12:02 +01:00
Luca Bösch
bbb8622464 MDL-77136 core_question: Newest versions get_questions_from_categories 2023-12-06 14:12:02 +01:00
Tim Hunt
7311dff041 MDL-80127 question engine: prevent fatal errors from old bad data 2023-12-06 11:45:26 +00:00
Tim Hunt
8f2f95bd28 MDL-80127 question engine: don't convert null to '' before storing 2023-12-06 11:43:30 +00:00
Andrew Nicols
61b5850a8c
MDL-80079 core: Correct incorrect arg to format_string::$options 2023-11-14 22:50:36 +08:00
Mark Johnson
ec5d7c3227 MDL-79639 quiz_statistics: Prevent database deadlocks
This changes the cache purge code to select IDs for deletion
first, rather than using a subquery in a DELETE, since this
risks causing a deadlock in MySQL.
2023-10-19 08:58:41 +01:00
Ilya Tregubov
76bd425474
Merge branch 'MDL-79279_401' of https://github.com/timhunt/moodle into MOODLE_401_STABLE 2023-10-10 11:24:47 +08:00
Sara Arjona
bd18e026bb
Merge branch 'MDL-69119-M401_angle_bracket_character_in_answers_not_escaped_in_moodle_xml_export_of_multiple_choice_calculated_questions' of https://github.com/ziegenberg/moodle into MOODLE_401_STABLE 2023-10-04 07:51:42 +02:00
Tim Hunt
848fd484d5 MDL-79279 qformat_xml: multianswer import should support idnumber
Fix suggested by Georg Maißer.
2023-10-03 20:43:15 +01:00
Daniel Ziegenberg
0839431f16
MDL-69119 qformat_xml: fix mc calculated export
The Moodle XML export of multiple choice calculated questions was
missing proper escaping of answers. Also the indentation of the
generated xml was off.

Signed-off-by: Daniel Ziegenberg <daniel@ziegenberg.at>
2023-10-03 12:23:20 +02:00
Andrew Nicols
2f6519d2de
Merge branch 'MDL-78580_401_STABLE' of https://github.com/marxjohnson/moodle into MOODLE_401_STABLE 2023-10-03 11:23:54 +08:00
Jun Pataleta
fbcb5793c3
Merge branch 'MDL-79254_401_STABLE' of https://github.com/marxjohnson/moodle into MOODLE_401_STABLE 2023-10-03 09:42:08 +08:00
Mark Johnson
fbb6717550 MDL-79254 quiz_statistics: Convert recalculate task to ad-hoc
Previously, quiz statistics processing happened on a scheduled task.
This task looked for all quizzes with completed attempts, then
determined if those quizzes had a statistics calculation that's newer
than the most recent attempt, then ran the statistics calculation if
needed. It was hard coded to stop processing after 1 hour.

The queries involved in determining which quizzes needed processing
weren't terribly efficient, and combined with the 1 hour limit this made
the statistics unusable on large sites, where they are the most useful.

This converts the scheduled task to an ad-hoc task, and uses an event
observer for mod_quiz\event\attempt_submitted to queue a task when
it is needed. This removes the need for a query to work out what needs
processing, and allows the task processing to be scaled up as needed.
2023-09-27 15:42:41 +01:00
Huong Nguyen
3720396bb4
Merge branch 'MDL-79332_401' of https://github.com/timhunt/moodle into MOODLE_401_STABLE 2023-09-18 18:57:01 +07:00
Mark Johnson
e6b80e155b MDL-78580 report_statistics: Prevent database deadlocks when viewing
If a quiz had a long job to calculate statstics running, this would
cause pages that may also attempt a recalculation (the statistics report
page or question bank) to load very slowly, and possibly result in a
database deadlock.

This change will firstly prevent the question bank page performing
analysis calculations at all, since these are not required for this
page, which will speed up loading and prevent deadlocks on this page.

Secondly, this adds a lock to the recalcuation process so that it cannot
run twice concurrently. This will present the user with a message to
indicate that it is waiting for a running calculation until it is
complete, and eventually it will timeout with a message and debugging.
2023-09-15 15:16:12 +01:00
Ilya Tregubov
a5f1d86040
Merge branch 'test4' of https://github.com/ilyatregubov/moodle into MOODLE_401_STABLE 2023-09-15 17:38:42 +08:00
Luca Bösch
767e147dac
MDL-79226 questions: check for UTF-8 encoding of the import file 2023-09-15 17:35:33 +08:00
Tim Hunt
aea590716a MDL-79332 Question stats: make loading robust to bad data
We were experiencing problems caused by old stats analysis in our
database, computed when there was a bug, causing fatal errors
when they were displayed. Therefore, this code needs to be robust to that.
2023-09-12 16:59:02 +01:00
Jun Pataleta
0c239cb841
MDL-78549 multianswer: Prevent default when clicking feedback trigger 2023-09-08 22:23:00 +08:00
Huong Nguyen
f8d8553da6
Merge branch 'MDL-78549-401' of https://github.com/junpataleta/moodle into MOODLE_401_STABLE 2023-09-08 22:23:00 +08:00
Jun Pataleta
192210f90e
Merge branch 'MDL-78874-401' of https://github.com/danghieu1407/moodle into MOODLE_401_STABLE 2023-09-05 12:05:42 +08:00
Jun Pataleta
b22a25f208
MDL-78549 qtype_multianswer: Configure feedback popover trigger via JS
* For some reason, the `data-trigger="hover focus"` does not work when
rendering the popover via HTML. It just defaults to click, so the
feedback popover for qtype_multianswer questions does not show on hover.
Configuring the feedback popover's trigger via JS seems to work.
2023-09-05 09:36:08 +08:00
Jun Pataleta
e6e6c7e7b3
MDL-79107 qtype_essay: Move non_form_fields.feature under qtype_essay 2023-08-31 21:07:07 +08:00
danghieu1407
fc3cbd5015 MDL-78874 accessibility: Improve descriptive text for check button 2023-08-24 20:47:58 +07:00
Andrew Nicols
558d836861
MDL-77381 qengine: Correct coverage for new test 2023-08-16 22:40:16 +08:00
Andrew Nicols
0d82ce2629
Merge branch 'MDL-77381-MOODLE_401_STABLE' of https://github.com/ScottVerbeek/moodle into MOODLE_401_STABLE 2023-08-16 22:40:12 +08:00
Jun Pataleta
770b11c3d9
Merge branch 'MDL-77378_401_v3' of https://github.com/TomoTsuyuki/moodle into MOODLE_401_STABLE 2023-08-10 18:44:14 +07:00
ScottVerbeek
59f7404d8b MDL-77381 question engine: don't query empty arrays 2023-08-08 09:04:00 +10:00
danghieu1407
1b4ee84aee MDL-78866 question: question_created trigger pre-saving extra fields 2023-08-01 15:59:57 +07:00
Tomo Tsuyuki
2ba3b8b27e MDL-77378 qtype_multianswer: Fix division by zero errors 2023-08-01 11:26:44 +10:00
Tim Hunt
0a6f40cb21
MDL-76757 delete questions: fix message generation logic
The order was getting scrambled.
2023-07-13 21:44:04 +02:00
Huong Nguyen
dcd80cff04
Merge branch 'MDL-76757-401' of https://github.com/danghieu1407/moodle into MOODLE_401_STABLE 2023-07-13 09:46:59 +07:00
Jake Dallimore
a6b769bddd
Merge branch 'MDL-77912_401' of https://github.com/timhunt/moodle into MOODLE_401_STABLE 2023-07-13 10:09:45 +08:00