ndunand / moodle-qtype_matrix

Source code of https://moodle.org/plugins/qtype_matrix
2 stars 10 forks source link

division by zero error #30

Closed ndunand closed 2 years ago

ndunand commented 9 years ago
Warning: Division by zero in /var/www/moodlecode/29/question/type/matrix/question.php on line 340
Call Stack
#   Time    Memory  Function    Location
1   0.0008  289984  {main}( )   ../processattempt.php:0
2   0.1631  10546352    quiz_attempt->process_submitted_actions( )  ../processattempt.php:130
3   0.1631  10550456    question_usage_by_activity->process_all_actions( )  ../attemptlib.php:1764
4   0.1641  10554872    question_usage_by_activity->process_action( )   ../questionusage.php:609
5   0.1641  10555056    question_attempt->process_action( ) ../questionusage.php:728
6   0.1641  10555680    qbehaviour_interactive->process_action( )   ../questionattempt.php:1233
7   0.1642  10556136    qbehaviour_interactive->process_submit( )   ../behaviour.php:166
8   0.1652  10578040    qbehaviour_interactivecountback->adjust_fraction( ) ../behaviour.php:206
9   0.1653  10579496    qtype_matrix_question->compute_final_grade( )   ../behaviour.php:91

What is line 340 in https://github.com/ndunand/moodle-qtype_matrix/blob/master/question.php#L340 supposed to be for ?

ndunand commented 2 years ago

fixed by #54