Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

If you POST without a :body, the client hangs #21

Closed
sbowman opened this issue Aug 24, 2011 · 5 comments
Closed

If you POST without a :body, the client hangs #21

sbowman opened this issue Aug 24, 2011 · 5 comments

Comments

@sbowman
Copy link

sbowman commented Aug 24, 2011

If you try to submit a POST request without any :body map or a string, the request will hang and never return.

@sbowman
Copy link
Author

sbowman commented Aug 24, 2011

Similar thing happens with PUT, but instead of hanging, I think the submission to the server is incorrect. I haven't investigated too much, but if I PUT to a Rails 2.3 app without a body, I receive:

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN">
<HTML>
  <HEAD><TITLE>Length Required</TITLE></HEAD>
  <BODY>
    <H1>Length Required</H1>
    WEBrick::HTTPStatus::LengthRequired
    <HR>
    <ADDRESS>
     WEBrick/1.3.1 (Ruby/1.8.7/2011-07-07) at
     localhost:8080
    </ADDRESS>
  </BODY>
</HTML>

@sbowman
Copy link
Author

sbowman commented Aug 24, 2011

If I add a dummy body in both cases, the call will work. That's my current work-around.

@sbowman
Copy link
Author

sbowman commented Aug 24, 2011

With a litte more investigation, I think the PUT problem is a Rails issue.

neotyk added a commit that referenced this issue Sep 19, 2011
Two tests added:
- test-post-no-body
- test-put-no-body

Both are sending no body.
@neotyk
Copy link
Collaborator

neotyk commented Sep 19, 2011

Hi Sean,

Thanks for bug report.
I failed to reproduce this issue: 146b191

Both POST and PUT are not hanging when issued w/o body. Please see: test-post-no-body and test-put-no-body.

Please let me know if you still think it is http.async.client issue.

@neotyk
Copy link
Collaborator

neotyk commented Sep 27, 2011

Can't reproduce

@neotyk neotyk closed this as completed Sep 27, 2011
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants