This project is archived and is in readonly mode.
406 Unacceptable received for something the Accept header has said it can take
-
Russell Garner
Attached 5991_tests.patch to demonstrate.
-
José Valim
- State changed from new to wontfix
- Importance changed from to Low
Yes, but this can't be fixed. Some browsers (cof cof IE) are really retarded when sending accept headers in the sense it may pass image/png or atom with higher priority than text/html. So rails tries to detect everything that looks like a bad browser request and defaults it to HTML. sorry, but You will need to pass :format => :atom as option to form_for or ensure in other way .atom is present at the end of the URL.
-
Russell Garner
If I found a way to make the above tests pass in addition to everyone else's, would you consider a patch? I'm actually hacking the
request.format = :atomin the controller action at the moment, but I don't believe serving a 406 when any agent (browser or otherwise) has said they can accept anything and there are formats there waiting is good HTTP. We're letting bad browsers like (cough cough ;)) IE dictate good HTTP-related server practice. -
José Valim
Yes, if you find a way to circumvent the issue, a patch is welcome. :)
