-
Notifications
You must be signed in to change notification settings - Fork 63
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Replace Timeout.timeout in Net:HTTP#connect
Use Socket.tcp's connect_timeout option instead
- Loading branch information
1 parent
d9ba437
commit 753cae3
Showing
1 changed file
with
7 additions
and
8 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
753cae3
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Doesn't this change the meaning of
open_timeout: 0
?With
Timeout.timeout
, 0 is equivalent tonil
, but withSocket.tcp
, 0 means 0.753cae3
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This change was reverted in 98caa38, not sure why. If there are edge cases like, it would have been nice to just take them into account and preserve the behavior, but it's a moot point now
753cae3
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You are correct though, I'll update my the monkeypatch I'm using, thanks!