@@ -54,8 +54,8 @@ module HTTP
5454 ?form: untyped ,
5555 ?json: untyped ,
5656 ?body: untyped ,
57- ?follow: bool ,
58- ?retriable: bool ,
57+ ?follow: bool | Hash[Symbol, untyped ] ,
58+ ?retriable: bool | Hash[Symbol, untyped ] ,
5959 ?base_uri: String | URI | nil ,
6060 ?persistent: String?,
6161 ?ssl_context: OpenSSL::SSL::SSLContext?
@@ -77,7 +77,7 @@ module HTTP
7777 def default_options= : (Hash[Symbol, untyped ] | Options opts) -> Options
7878 def nodelay : () -> Session
7979 def use : (*(Symbol | Hash[Symbol, Hash[Symbol, untyped ]]) features) -> Session
80- def retriable : (** untyped options ) -> Session
80+ def retriable : (?tries: Integer?, ?delay: (Numeric | ^(Integer) -> Numeric)?, ?exceptions: Array[ singleton (Exception)]?, ?retry_statuses: untyped , ?on_retry: (^(Request, Exception?, Response?) -> void )?, ?max_delay: Numeric?, ?should_retry: (^(Request, Exception?, Response?, Integer) -> bool )? ) -> Session
8181
8282 private
8383
@@ -116,8 +116,8 @@ module HTTP
116116 ?form: untyped ,
117117 ?json: untyped ,
118118 ?body: untyped ,
119- ?follow: bool ,
120- ?retriable: bool ,
119+ ?follow: bool | Hash[Symbol, untyped ] ,
120+ ?retriable: bool | Hash[Symbol, untyped ] ,
121121 ?base_uri: String | URI | nil ,
122122 ?persistent: String?,
123123 ?ssl_context: OpenSSL::SSL::SSLContext?
@@ -165,8 +165,8 @@ module HTTP
165165 ?form: untyped ,
166166 ?json: untyped ,
167167 ?body: untyped ,
168- ?follow: bool ,
169- ?retriable: bool ,
168+ ?follow: bool | Hash[Symbol, untyped ] ,
169+ ?retriable: bool | Hash[Symbol, untyped ] ,
170170 ?base_uri: String | URI | nil ,
171171 ?persistent: String?,
172172 ?ssl_context: OpenSSL::SSL::SSLContext?
@@ -489,8 +489,8 @@ module HTTP
489489 ?form: untyped ,
490490 ?json: untyped ,
491491 ?body: untyped ,
492- ?follow: bool ,
493- ?retriable: bool ,
492+ ?follow: bool | Hash[Symbol, untyped ] ,
493+ ?retriable: bool | Hash[Symbol, untyped ] ,
494494 ?base_uri: String | URI | nil ,
495495 ?persistent: String?,
496496 ?ssl_context: OpenSSL::SSL::SSLContext?
@@ -586,9 +586,10 @@ module HTTP
586586
587587 def self.parse : (untyped uri) -> URI
588588 def self.form_encode : (untyped form_values, ?sort: bool ) -> String
589- def self.percent_encode : (String? string) -> String?
589+ def self.percent_encode : (String string) -> String
590+ | (String? string) -> String?
590591
591- def initialize : (?Hash[Symbol, untyped ] options ) -> void
592+ def initialize : (?scheme: String?, ?user: String?, ?password: String?, ?host: String?, ?port: Integer?, ?path: String?, ?query: String?, ?fragment: String? ) -> void
592593 def == : (untyped other) -> bool
593594 def eql? : (untyped other) -> bool
594595 def hash : () -> Integer
@@ -620,7 +621,7 @@ module HTTP
620621
621622 private
622623
623- def process_ipv6_brackets : (untyped raw_host, ?brackets: bool ) -> untyped
624+ def process_ipv6_brackets : (untyped raw_host, ?brackets: bool ) -> String?
624625 end
625626
626627 # Supported HTTP method verbs
@@ -1119,7 +1120,7 @@ module HTTP
11191120 attr_reader options: Hash[Symbol, Numeric]
11201121 attr_reader socket: untyped
11211122
1122- def initialize : (** Numeric) -> void
1123+ def initialize : (?read_timeout: Numeric?, ?write_timeout: Numeric?, ?connect_timeout: Numeric?, ?global_timeout: Numeric? ) -> void
11231124 def connect : (untyped socket_class, String host, Integer port, ?nodelay: bool ) -> void
11241125 def connect_ssl : () -> void
11251126 def close : () -> void
0 commit comments