Wacky error when using the inline edit for bug task project in Chromium

Bug #423149 reported by Graham Binns
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Launchpad itself
Fix Released
High
Tim Penhey
lazr.restful
Fix Released
High
Leonard Richardson

Bug Description

What happens:
I tried to retarget bug 208239 from Launchpad Bugs to Launchpad Registry in Chromium and got the following error in a hideous red popup, which appears under the edit icon for the bug description. I don't know if the look of the popup is the fault of YUI or Chromium, and I'll file that as a separate bug.

The error is: Bad Request X-HTTP-Method-Override can only be used with a POST request

What should happen:
1) This error shouldn't appear (why should I, as a user, care about it?)
or
2) The error should actually be meaningful to the user. I don't know what this means off the top of my head, and I know at least something about HTTP.

Related branches

Revision history for this message
Eleanor Berger (intellectronica) wrote :

This is a known bug which requires changes to lazr.restful to fix correctly. As an immediate fix we should disable the AJAX control on Chromium.

Revision history for this message
Tim Penhey (thumper) wrote :

We've figured this out. :-)

Changed in launchpad:
assignee: nobody → Leonard Richardson (leonardr)
status: Triaged → In Progress
tags: added: thunderdome
Revision history for this message
Leonard Richardson (leonardr) wrote :

lazr.restful is too zealous in validating the X-HTTP-Method-Override header. Our rule is that you're only allowed to use it in a POST request, and if you use it in any other kind of request, it's an error.

Chromium is making a POST request with X-HTTP-Method-Override set to PATCH. The response is a 301 redirect. (It should be 303, but that doesn't change this analysis.) Chromium makes a follow-up GET request, and *propagates* the X-HTTP-Method-Override header in the second request. So, Launchpad interprets the second request as someone trying to turn a GET request into a POST request by setting X-HTTP-Method-Override.

In the interests of being liberal what we accept, we will ignore X-HTTP-Method-Override unless the request is a POST request.

affects: launchpad → lazr.restful
Tim Penhey (thumper)
Changed in lazr.restful:
status: In Progress → Fix Released
Changed in launchpad:
status: New → In Progress
assignee: nobody → Tim Penhey (thumper)
importance: Undecided → High
Tim Penhey (thumper)
Changed in launchpad:
status: In Progress → Fix Committed
Revision history for this message
Launchpad QA Bot (lpqabot) wrote :
Changed in launchpad:
milestone: none → 11.02
tags: added: qa-needstesting
tags: added: qa-untestable
removed: qa-needstesting
Revision history for this message
Launchpad QA Bot (lpqabot) wrote :

Fixed in stable r12256 (http://bazaar.launchpad.net/~launchpad-pqm/launchpad/stable/revision/12256) by a commit, but not testable.

tags: added: qa-needstesting
removed: qa-untestable
Revision history for this message
Launchpad QA Bot (lpqabot) wrote :
tags: added: qa-untestable
removed: qa-needstesting
Revision history for this message
Launchpad QA Bot (lpqabot) wrote :

Fixed in stable r12256 (http://bazaar.launchpad.net/~launchpad-pqm/launchpad/stable/revision/12256) by a commit, but not testable.

Tim Penhey (thumper)
tags: added: qa-ok
removed: qa-untestable
Revision history for this message
Robert Collins (lifeless) wrote :

rev 12251 is bad - causing the description field of bugs to be uneditable; wgrant points out that its not the lazr.restful change breaking it (though it may be implicated). There are later lazr.restful changes so a rollback needs to be fully tested in ec2.

tags: added: bad-commit-12251 qa-bad
removed: qa-ok
William Grant (wgrant)
tags: added: qa-ok
removed: qa-bad
William Grant (wgrant)
Changed in launchpad:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.