Coderunner return problem

Coderunner return problem

by TOLGA HAYIT -
Number of replies: 1

Hello everyone,

We encountered an issue after upgrading Coderunner. For some (not all) C++ code blocks, the attached error occurs when the code is submitted.
As an example, I am also sharing the editing screen of a question that triggers the error. Simple code submissions work fine, but this particular code causes an error.
We strongly believe that the issue is not caused by the code itself.
Thank you in advance for your help!

Attachment Editing-a-CodeRunner-question-QA.jpg
Attachment Screenshot .png
In reply to TOLGA HAYIT

Re: Coderunner return problem

by Richard Lobb -
I agree you shouldn't be seeing a rather inelegant traceback like that.

But the error you're getting is from the following three lines of code within CodeRunner:

$header = $resulttable[0];
$ishiddencolumn = -1;
$n = count($header);

Since you're using a combinator template grader, the resulttable variable is taken directly from the output of your grader. It should be a list of lists, where the first list is the header row of the table. This should be a list of strings (the column headers), but the error message suggests it's actually just a single string.

However, if you're sure that your resulttable is indeed a list of lists of strings, please post back with an xml export of your question plus an export of its prototype.