How To / General

XML-RPC Error (28260048): Invalid response value detected | ERRORCODE: invalidre

  • Justin
  • Topic Author
  • Offline
  • Premium Member
  • Premium Member
More
6 years 8 months ago #1 by Justin
Hi

I am using Joomdle version 1.2.4 and to display the grades I am using the "User courses grades" view

When trying to view the grades I get the error below, strange thing is the error seems to only show on one of the courses the rest display correctly.
This course displayed correctly previously but all of a sudden it does not.

XML-RPC Error (28260048): Invalid response value detected | ERRORCODE: invalidresponse

Please Log in or Create an account to join the conversation.

More
6 years 8 months ago #2 by Antonio Durán
Hi.

First thing is to enable debugging in Moodle, and then trigger the error, so we can try to have more info about it.

Please Log in or Create an account to join the conversation.

  • Justin
  • Topic Author
  • Offline
  • Premium Member
  • Premium Member
More
6 years 8 months ago #3 by Justin
XML-RPC Error (28260048): Invalid response value detected | DEBUG INFO: data => Invalid response value detected: items => Invalid response value detected: Error in response - Missing following required key in a single structure: due | ERRORCODE: invalidresponse

Please Log in or Create an account to join the conversation.

More
6 years 8 months ago #4 by Antonio Durán
Hi. I could not replicate the error, but looking at the code I can give you a proposed fix so you can try it. If it does not work, we can investigate further.

Change is to be made in file: moodle/auth/joomdle/auth.php
Function: get_grade_user_report
After this block:
Code:
if ($module) { $conditions = array ('course' => $item->courseid, 'module' => $module->id, 'instance' => $item->iteminstance); $cm = $DB->get_record('course_modules', $conditions); $category_item['course_module_id'] = $cm->id; switch ($item->itemmodule) { case 'quiz': $conditions = array ('id' => $item->iteminstance); $quiz = $DB->get_record('quiz', $conditions); $category_item['due'] = $quiz->timeclose; break; case 'assignment': $conditions = array ('id' => $item->iteminstance); $assignment = $DB->get_record('assignment', $conditions); $category_item['due'] = $assignment->timedue; break; default: $category_item['due'] = 0; break; } }

Add:
Code:
else $category_item['due'] = 0;

Please test and let us know how it goes.

Please Log in or Create an account to join the conversation.

  • Justin
  • Topic Author
  • Offline
  • Premium Member
  • Premium Member
More
6 years 8 months ago #5 by Justin
Hi Antonio

I tested it, but it had no effect, the error still remains

Please Log in or Create an account to join the conversation.

More
6 years 8 months ago #6 by Antonio Durán
Is it possible to share a course backup so I can test it locally? No student data is needed.

Please Log in or Create an account to join the conversation.

  • Justin
  • Topic Author
  • Offline
  • Premium Member
  • Premium Member
More
6 years 8 months ago #7 by Justin
Hi

Sorry I have not had a chance to send you a copy of the course yet.
I am starting to wonder if it is the course though, because I did some additional checks and found 5 other courses that give the exact same error.

What puzzles me is that these courses are some of the first I created and their grade books did work, and now don't even though nothing has changed in the courses them selves.

Please Log in or Create an account to join the conversation.

More
6 years 7 months ago #8 by Antonio Durán
Hi Justin.

"due" field was added recently, so maybe those courses worked fine before the upgrade? Anyway, I think it is course related, as it works in some and not in others. I can check when you send me a non working course so I can test.

Please Log in or Create an account to join the conversation.