Thanks very much for the added detail. I filed an issue on the Github project 
for the Python server, and within hours another Githubber had posted a pull 
request fixing the bug. The server was just not aware of what to do if it got 
such an OPTIONS request, so it was falling over.

Walter

On Apr 13, 2012, at 5:26 AM, Victor wrote:

> It seems to be an issue on their server (BaseHTTP/0.3 Python/2.7.1+ according 
> to FireBug). I'll file a bug and see what happens.
> 
> XHR without setRequestHeader sends usual 'GET' request:
> 
> Request URL: http://zip.elevenbasetwo.com/?zip=a
> Request Method: GET
> Status Code: 404 Not Found
> Request Headers
> Accept: */*
> Accept-Charset: windows-1251,utf-8;q=0.7,*;q=0.3
> Accept-Encoding: gzip,deflate,sdch
> Accept-Language: ru-RU,ru;q=0.8,en-US;q=0.6,en;q=0.4
> Connection: keep-alive
> Host: zip.elevenbasetwo.com
> Origin: https://groups.google.com
> User-Agent: Mozilla/5.0 (X11; Linux i686) AppleWebKit/535.19 (KHTML, like 
> Gecko) Chrome/18.0.1025.142 Safari/535.19
> Response Headers
> Access-Control-Allow-Origin: *
> Connection: close
> Content-Type: text/plain
> Date: Fri, 13 Apr 2012 09:16:07 GMT
> Server: BaseHTTP/0.3 Python/2.7.1+
> 
> XHR with any setRequestHeader sends first 'OPTIONS' request (so-called 
> preflight):
> 
> Request URL: http://zip.elevenbasetwo.com/?zip=a
> Request Method: OPTIONS
> Status Code: 501 Not Implemented
> Request Headers
> Accept: */*
> Accept-Charset: windows-1251,utf-8;q=0.7,*;q=0.3
> Accept-Encoding: gzip,deflate,sdch
> Accept-Language: ru-RU,ru;q=0.8,en-US;q=0.6,en;q=0.4
> Access-Control-Request-Headers: x-xxx, origin
> Access-Control-Request-Method: GET
> Connection: keep-alive
> Host: zip.elevenbasetwo.com
> Origin: https://groups.google.com
> User-Agent: Mozilla/5.0 (X11; Linux i686) AppleWebKit/535.19 (KHTML, like 
> Gecko) Chrome/18.0.1025.142 Safari/535.19
> Response Headers
> Connection: close
> Content-Type: text/html
> Date: Fri, 13 Apr 2012 09:20:32 GMT
> Server: BaseHTTP/0.3 Python/2.7.1+
> 
> It seems that some browsers (like Firefox and WebKit-based) may send CORS 
> requests without preflight for text/plain resources when no additional 
> headers are set. In other cases they send preflighted 'OPTIONS' request, 
> which is not implemented in this 'BaseHTTP/0.3 Python/2.7.1+' server.
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "Prototype & script.aculo.us" group.
> To view this discussion on the web visit 
> https://groups.google.com/d/msg/prototype-scriptaculous/-/6xIQrvgSIqsJ.
> To post to this group, send email to prototype-scriptaculous@googlegroups.com.
> To unsubscribe from this group, send email to 
> prototype-scriptaculous+unsubscr...@googlegroups.com.
> For more options, visit this group at 
> http://groups.google.com/group/prototype-scriptaculous?hl=en.

-- 
You received this message because you are subscribed to the Google Groups 
"Prototype & script.aculo.us" group.
To post to this group, send email to prototype-scriptaculous@googlegroups.com.
To unsubscribe from this group, send email to 
prototype-scriptaculous+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/prototype-scriptaculous?hl=en.

Reply via email to