Moodle - 调用Web服务返回错误/ restore_not_executable_awaiting_required

时间:2015-11-20 01:41:09

标签: moodle

我遇到了这个错误。 试图调用自定义Web服务,执行测验复制(duplicate_module()),其编辑(quiz_update_instance())和最后缓存清除(rebuild_course_cache)。

在我向测验添加问题之前,它完美无缺。然后它返回错误:

error/restore_not_executable_awaiting_required | ERRORCODE: restore_not_executable_awaiting_required. Fault code: 78563441. Actual reply from server: <?xml version="1.0" encoding="UTF-8"?> <methodResponse><fault><value><struct><member><name>faultCode</name><value><int>78563441</int></value></member><member><name>faultString</name><value><string>error/restore_not_executable_awaiting_required | ERRORCODE: restore_not_executable_awaiting_required</string></value></member></struct></value></fault></methodResponse>

服务器设置:

max_execution_time=14400
max_input_time=14400

代码:

$context = stream_context_create(array('http' => array( 'method' => "POST", 'header' => "Content-Type: text/xml", 'content' => $request, 'timeout' => 14000000, ))); 
$path = $this->url . "/webservice/xmlrpc/server.php?wstoken=" . $this->token; 
$file = file_get_contents($path, false, $context);

你能帮我找一下错误的原因吗?谢谢!

1 个答案:

答案 0 :(得分:0)

在将Moodle 3.1升级到3.5.1之后,我遇到了相同的问题,并在Moodle 3.5.2上找到了修复程序,我对此进行了挑选: https://tracker.moodle.org/browse/MDL-62897