Merge lp:~lifeless/js-oopsd/post into lp:js-oopsd
| Status: | Merged |
|---|---|
| Merged at revision: | 13 |
| Proposed branch: | lp:~lifeless/js-oopsd/post |
| Merge into: | lp:js-oopsd |
| Diff against target: |
104 lines (+42/-6) 3 files modified
NEWS (+3/-0) js_oopsd/main.py (+14/-2) js_oopsd/tests/test_main.py (+25/-4) |
| To merge this branch: | bzr merge lp:~lifeless/js-oopsd/post |
| Related bugs: |
| Reviewer | Review Type | Date Requested | Status |
|---|---|---|---|
| John A Meinel (community) | code* | Approve on 2012-09-10 | |
| Ian Booth (community) | 2012-09-10 | Approve on 2012-09-10 | |
|
Review via email:
|
|||
Description of the Change
keep browsers happier - implement CORS rules to permit any browser to use
POST or GET, and permit preflight checks.
| Robert Collins (lifeless) wrote : | # |
| Ian Booth (wallyworld) wrote : | # |
Looks ok, but I'm not really sufficiently across the finer detail of the specs to know for sure that nothing unintended is not being introduced. So a conditional approval from me.
| John A Meinel (jameinel) wrote : | # |
I think the headers listed here aren't quite correct. You mention wanting to support GET and POST, but you list PUT and DELETE.
I also think it is good to test the exact headers in the test suite, so that changing the input in 'main.py' won't have the test suite still pass without updating. (It is good to test that the headers make it into the output, but we *also* need to test that the headers contain the fields we need in the real world.)
Beyond that, I think getting something landed, so it can be tested with real browsers is the most important thing. Having an allow '*' is a little concerning for me, I'd be happier with an Allow *.canonical.com *.launchpad.net or something like that, but I haven't dug into the spec to be sure its all ok.
And in the end, I think we're pretty confident that POST/GET from OOPS isn't going to be a cross-site-
So approve with some tweaks.
- 14. By Robert Collins on 2012-09-10
-
Fix methods, make one non-circular test.

https:/ /developer. mozilla. org/en- US/docs/ HTTP_access_ control and http:// www.w3. org/TR/ cors if you want the train wreck that is the specs.