Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

amcat.codingjob.results gives error 500 #9

Open
jogrue opened this issue Nov 17, 2018 · 0 comments
Open

amcat.codingjob.results gives error 500 #9

jogrue opened this issue Nov 17, 2018 · 0 comments

Comments

@jogrue
Copy link

jogrue commented Nov 17, 2018

Hello,

I am trying to directly access the results from coding jobs through R with this command (if you do need the real URL, project id, and job id, please, tell me):

tmp <- amcatr::amcat.codingjob.results(conn = amcat_con,
                                       project = 1,
                                       job = 1234)

R then reports something like this:

GET http://abcd.amcat.nl/api/v4/projects/1/codingjobs/1234/codingschemafields/?page_size=1000&format=rda&page=1
GET http://abcd.amcat.nl/api/v4/projects/1/codingjobs/1234/codebooks/?page_size=99999&format=json&page=1
GET http://abcd.amcat.nl/api/v4/projects/1/codingjobs/1234/coded_articles/?page_size=1000&format=rda&page=1
Fehler in amcat.getURL(conn, path, page_filters, post = post, post_options,  : 
  Unexpected Response Code 500
This seems to be an AmCAT server error. Please see the server logs or create an issue at http://github.com/amcat/amcat/issues
Response written to /tmp/RtmpLjj30p/file52d339f0eeef

The response then reads like this:

{
  "status": 500,
  "details": "TypeError: Don't know how to convert <class 'datetime.datetime'> to R",
  "error": true,
  "message": "500 : An Error has occurred",
  "description": "The server encountered an internal error or misconfiguration and\n                     was unable to complete your request."
}

So the problem seems to be calling http://abcd.amcat.nl/api/v4/projects/1/codingjobs/1234/coded_articles/?page_size=1000&format=rda&page=1 with the rda format (and here with datetime conversion). Opening the URL with format json instead of rda does not return an error. Our server reports AmCAT version 3.5rc1 in the web interface.

Best regards,
Johann

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant