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

Fix status code for auth failure, and add DepositCompleted exception. #21

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions build.json
Original file line number Diff line number Diff line change
Expand Up @@ -119,6 +119,11 @@
"root" : "diagrams/structure.png",
"out" : "structure.png",
"process" : false
},
{
"root": "tables/error-types.csv",
"out": "error-types.csv",
"process": false
}
],

Expand Down
3 changes: 2 additions & 1 deletion src/tables/error-types.csv
Original file line number Diff line number Diff line change
@@ -1,10 +1,11 @@
Error Type,Error Code,Reason
AuthenticationFailed,403,"The request supplied invalid credentials, or no credentials, when the server was expecting to authenticate the request."
AuthenticationFailed,401,"The request supplied invalid credentials, or no credentials, when the server was expecting to authenticate the request."
BadRequest,400,The request did not meet the standard specified by the SWORD protocol. This error can be used when no other error is appropriate
ByReferenceFileSizeExceeded,400,"The client supplied a By-Reference deposit file, which specified a file size which exceeded the server's limit"
ByReferenceNotAllowed,412,The client attempted to carry out a By-Reference deposit on a server which does not support it
ContentMalformed,400,"The body content of the request was malformed in some way, such that the server cannot read it correctly."
ContentTypeNotAcceptable,415,The `Content-Type` header specifies a content type of the request which is in a format that the server cannot accept.
DepositComplete,403,"The deposit is not In-Progress, so can no longer be altered."
DigestMismatch,412,One or more of the Digests that the server checked did not match the deposited content
ETagNotMatched,412,The client supplied an `If-Match` header which did not match the current `ETag` for the resource being updated.
ETagRequired,412,"The client did not supply an `If-Match` header, when one was required by the server"
Expand Down