[Distutils] [PEP 243] upload status is bogus
Mon Mar 26 17:59:01 2001
I just read thru PEP 243 and got to the section "Return Data". That
information is bogus. HTTP already provides the upload client with various
status codes. Specifically, let's look at the list in the PEP:
PEP value HTTP Status
SUCCESS 200 (Ok)
FAILURE 4xx or 5xx
TRYAGAIN 4xx or 5xx
The PEP lists "resource shortage" as a possible TRYAGAIN error. That would
map to 507 (Insufficent Storage). I'm sure there are other values that would
make sense within this area.
The PEP goes on to say that a human-readable string should provide further
information. That is exactly what the body of the HTTP response is for.
So... the answer here is to use the HTTP status codes like they're intended,
and to use the HTTP response body as they're intended. This beats added
another protocol layer on top of the response.
p.s. I'm not on the Distutils-SIG; I'd appreciate a CC for replies.
Greg Stein, http://www.lyra.org/