Moodle

Essay question type broken

Details

  • Type: Bug Bug
  • Status: Closed Closed
  • Priority: Blocker Blocker
  • Resolution: Fixed
  • Affects Version/s: 1.9.1
  • Fix Version/s: 1.9.2, 2.0
  • Component/s: Questions
  • Labels:
    None
  • Affected Branches:
    MOODLE_19_STABLE
  • Fixed Branches:
    MOODLE_19_STABLE, MOODLE_20_STABLE

Description

Create an essay question with no feedback or general feedback. Previewing or attempting the quiz leads to a blank page. PHP error indicates:

Fatal error: Call to undefined method question_essay_qtype::extra_answer_fields() in /srv/www/htdocs/moodle_19/question/type/questiontype.php on line 440

extra_answer_fields() is NOT defined anywhere in this class or in any of its children classes. extra_question_fields(), however, is defined.

Activity

Hide
Jacques Monnard added a comment -

I just noticed this bug as well when doing a backup of a course with quizzes.
Apparently, the following three lines were deleted by mistake at line 104 in question/type/questiontype.php :

function extra_answer_fields() { return null; }

I've just added them back in, and everything seems to work fine.

Show
Jacques Monnard added a comment - I just noticed this bug as well when doing a backup of a course with quizzes. Apparently, the following three lines were deleted by mistake at line 104 in question/type/questiontype.php : function extra_answer_fields() { return null; } I've just added them back in, and everything seems to work fine.
Hide
Skip Marshall added a comment -

Nice catch. This resolved the problem.

Show
Skip Marshall added a comment - Nice catch. This resolved the problem.
Hide
Tim Hunt added a comment -

Nicholas, you have a comment above saying 'fixed', but the bug is not actually resolved as fixed. Then there are the other comments. So I am confused. Can you help me. Thanks.

Show
Tim Hunt added a comment - Nicholas, you have a comment above saying 'fixed', but the bug is not actually resolved as fixed. Then there are the other comments. So I am confused. Can you help me. Thanks.
Hide
Nicolas Connault added a comment -

Yes Tim, I fixed it in HEAD but forgot 1.9. I am closing this now

Show
Nicolas Connault added a comment - Yes Tim, I fixed it in HEAD but forgot 1.9. I am closing this now
Hide
Jerome Mouneyrac added a comment -

tested in 1.9. It works. Thanks.

Show
Jerome Mouneyrac added a comment - tested in 1.9. It works. Thanks.

People

Vote (2)
Watch (5)

Dates

  • Created:
    Updated:
    Resolved: