SWORD plugin leads to continuous loading wheel

We have a journal that would like to use the SWORD plugin, but are having problems configuring it. We’ve not dealt with SWORD before, so we’re a little unsure of whether the problem is on our side, the plugin, or the configuration being entered. The journal platform is OJS 3.3.0.

1 - we’re able to install the plugin ok
2 - we can then create a Deposit Point by adding the Name, Deposit Point URL, Username and Password to the SWORD settings tab. The type is set to Automatic. The settings form saves ok.
3 - when we then try to accept a submission, we get the continuous loading wheel and can’t progress the submission at all without disabling the plugin (no error messages displayed)

I’m not entirely sure whether the Deposit Point URL is correct or not. GitHub - pkp/sword: Allow Journal Managers and (optionally) Authors to deposit articles via the SWORD protocol has a link to some documentation, but that now redirects to another page.

Any pointers much appreciated.

Hi @TimW!

I’d suggest working with a “manual” deposit type first, until you’re sure that you’ve got the details configured correctly. It’s easier to experiment with. (This will involve using the import/export tools to trigger the deposits.)

Frequently when things are misconfigured the system on the other end will respond with something that the SWORD library can’t properly parse. Unfortunately this is a bit difficult to debug unless you can capture the response that’s being sent. The quick and dirty way to capture the response is to temporarily edit the library that the SWORD plugin uses to interact with the other system. Edit libs/swordappv2/swordappclient.php relative to the SWORD plugin’s installation directory and look for code like:

$sac_resp = curl_exec($sac_curl);

Add an error_log call to capture it in the PHP error log:

$sac_resp = curl_exec($sac_curl);
error_log(print_r($sac_resp,true)); // TEMPORARILY dump response to log

(There are several calls like this in the SWORD library.)

Alec Smecher
Public Knowledge Project Team

1 Like

Thanks - will give it a go!