RunestoneServer
RunestoneServer copied to clipboard
self.getOutput() not working in the Edit Question view of Instructor/Assignment
Please check the current issues Many bug reports are duplicates, this just creates more work for us. Searching the issues first may give you your answer or a workaround! If not adding new information to an existing report is much more helpful than a new report.
What Course are you in LHSIntroCS_2022
What Page were you on Instructor/Assignment/Edit Question - I was editing lhs_3_1 within Problem Set 3
What is your username lhsadmin
Describe the bug When editing the questions, I pressed the Generate/View HTML. The questions appeared and I ran the program to test it out. But the correct answer was showing up as incorrect. The self.getOutput() seems to be returning the empty string - so it is failing the test assertion. I've attached a picture and you can see that in the "Expected Value" column, it is an empty string. Normally, it is whatever was printed out in the console.
Traceback n/a
Javascript Errors n/a
That is odd, I just tried to recreate the problem by writing my own question and it worked fine for me.
Is there anything in the console that might be a clue? I upgraded skulpt about 2 weeks ago so that was my first fear was that I had missed something in the upgrade. But that does not seem to be the case.
Hmmm... was this within the Edit Question of the Instruction tab? After editing (generating the HTML and saving), and running the problem in Instruction tab or in an Assignment, the problem will run OK.
It is just that within the Edit Question page, when generating the HTML and testing it within that view, the self.getOutput() did not seem to work and was very confusing to me at first - thinking that I had done something wrong with my editing.
But in fact, there was nothing really wrong after saving it and running it in other views.
I went to an assignment in a thinkcspy based test book and created a new question...
It all uses the same function to render the question whether you are editing, or previewing, or creating a new question...
But it would be good to get to the bottom of this.
Stale issue message