httpx 0.15.3 → 0.17.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (109) hide show
  1. checksums.yaml +4 -4
  2. data/doc/release_notes/0_15_4.md +5 -0
  3. data/doc/release_notes/0_16_0.md +93 -0
  4. data/doc/release_notes/0_16_1.md +5 -0
  5. data/doc/release_notes/0_17_0.md +49 -0
  6. data/lib/httpx/adapters/faraday.rb +3 -11
  7. data/lib/httpx/adapters/webmock.rb +2 -2
  8. data/lib/httpx/buffer.rb +1 -1
  9. data/lib/httpx/callbacks.rb +1 -1
  10. data/lib/httpx/chainable.rb +15 -8
  11. data/lib/httpx/connection/http1.rb +18 -10
  12. data/lib/httpx/connection/http2.rb +14 -21
  13. data/lib/httpx/connection.rb +6 -7
  14. data/lib/httpx/errors.rb +11 -11
  15. data/lib/httpx/headers.rb +1 -1
  16. data/lib/httpx/io/ssl.rb +2 -2
  17. data/lib/httpx/io/tls.rb +1 -1
  18. data/lib/httpx/options.rb +108 -81
  19. data/lib/httpx/parser/http1.rb +11 -7
  20. data/lib/httpx/plugins/aws_sigv4.rb +10 -9
  21. data/lib/httpx/plugins/compression.rb +12 -11
  22. data/lib/httpx/plugins/cookies/cookie.rb +4 -2
  23. data/lib/httpx/plugins/cookies/jar.rb +20 -1
  24. data/lib/httpx/plugins/cookies.rb +20 -7
  25. data/lib/httpx/plugins/digest_authentication.rb +19 -15
  26. data/lib/httpx/plugins/expect.rb +19 -15
  27. data/lib/httpx/plugins/follow_redirects.rb +9 -9
  28. data/lib/httpx/plugins/grpc/call.rb +4 -1
  29. data/lib/httpx/plugins/grpc.rb +73 -47
  30. data/lib/httpx/plugins/h2c.rb +7 -3
  31. data/lib/httpx/plugins/multipart/decoder.rb +187 -0
  32. data/lib/httpx/plugins/multipart/mime_type_detector.rb +3 -3
  33. data/lib/httpx/plugins/multipart/part.rb +2 -2
  34. data/lib/httpx/plugins/multipart.rb +14 -0
  35. data/lib/httpx/plugins/ntlm_authentication.rb +12 -10
  36. data/lib/httpx/plugins/proxy/socks4.rb +2 -1
  37. data/lib/httpx/plugins/proxy/socks5.rb +2 -1
  38. data/lib/httpx/plugins/proxy/ssh.rb +20 -13
  39. data/lib/httpx/plugins/proxy.rb +10 -10
  40. data/lib/httpx/plugins/retries.rb +25 -21
  41. data/lib/httpx/plugins/stream.rb +2 -3
  42. data/lib/httpx/plugins/upgrade.rb +7 -6
  43. data/lib/httpx/registry.rb +2 -2
  44. data/lib/httpx/request.rb +10 -19
  45. data/lib/httpx/resolver/https.rb +0 -2
  46. data/lib/httpx/resolver/native.rb +15 -3
  47. data/lib/httpx/resolver/resolver_mixin.rb +2 -1
  48. data/lib/httpx/response.rb +72 -38
  49. data/lib/httpx/selector.rb +6 -7
  50. data/lib/httpx/session.rb +34 -21
  51. data/lib/httpx/session2.rb +23 -0
  52. data/lib/httpx/transcoder/body.rb +1 -1
  53. data/lib/httpx/transcoder/chunker.rb +2 -1
  54. data/lib/httpx/transcoder/form.rb +20 -0
  55. data/lib/httpx/transcoder/json.rb +12 -0
  56. data/lib/httpx/transcoder.rb +62 -1
  57. data/lib/httpx/utils.rb +2 -2
  58. data/lib/httpx/version.rb +1 -1
  59. data/lib/httpx.rb +6 -3
  60. data/sig/buffer.rbs +3 -1
  61. data/sig/chainable.rbs +30 -29
  62. data/sig/connection/http1.rbs +11 -5
  63. data/sig/connection/http2.rbs +16 -5
  64. data/sig/connection.rbs +23 -11
  65. data/sig/errors.rbs +35 -1
  66. data/sig/headers.rbs +20 -19
  67. data/sig/httpx.rbs +4 -1
  68. data/sig/loggable.rbs +3 -1
  69. data/sig/options.rbs +45 -34
  70. data/sig/parser/http1.rbs +3 -3
  71. data/sig/plugins/authentication.rbs +1 -1
  72. data/sig/plugins/aws_sdk_authentication.rbs +5 -1
  73. data/sig/plugins/aws_sigv4.rbs +13 -5
  74. data/sig/plugins/basic_authentication.rbs +1 -1
  75. data/sig/plugins/compression.rbs +4 -6
  76. data/sig/plugins/cookies/cookie.rbs +5 -7
  77. data/sig/plugins/cookies/jar.rbs +9 -10
  78. data/sig/plugins/cookies.rbs +4 -5
  79. data/sig/plugins/digest_authentication.rbs +2 -3
  80. data/sig/plugins/expect.rbs +2 -4
  81. data/sig/plugins/follow_redirects.rbs +3 -5
  82. data/sig/plugins/grpc.rbs +4 -7
  83. data/sig/plugins/h2c.rbs +0 -2
  84. data/sig/plugins/multipart.rbs +64 -10
  85. data/sig/plugins/ntlm_authentication.rbs +2 -3
  86. data/sig/plugins/persistent.rbs +3 -8
  87. data/sig/plugins/proxy/ssh.rbs +4 -4
  88. data/sig/plugins/proxy.rbs +13 -13
  89. data/sig/plugins/push_promise.rbs +0 -2
  90. data/sig/plugins/retries.rbs +4 -8
  91. data/sig/plugins/stream.rbs +1 -1
  92. data/sig/plugins/upgrade.rbs +2 -3
  93. data/sig/pool.rbs +1 -2
  94. data/sig/registry.rbs +1 -1
  95. data/sig/request.rbs +11 -8
  96. data/sig/resolver/native.rbs +12 -6
  97. data/sig/resolver/resolver_mixin.rbs +4 -5
  98. data/sig/resolver/system.rbs +2 -0
  99. data/sig/resolver.rbs +7 -0
  100. data/sig/response.rbs +24 -12
  101. data/sig/selector.rbs +11 -9
  102. data/sig/session.rbs +22 -23
  103. data/sig/transcoder/body.rbs +6 -1
  104. data/sig/transcoder/chunker.rbs +8 -2
  105. data/sig/transcoder/form.rbs +3 -1
  106. data/sig/transcoder/json.rbs +2 -0
  107. data/sig/transcoder.rbs +13 -5
  108. data/sig/utils.rbs +2 -0
  109. metadata +12 -2
@@ -3,13 +3,17 @@ module HTTPX
3
3
  include Callbacks
4
4
  include Loggable
5
5
 
6
+ UPCASED: Hash[String, String]
7
+ MAX_REQUESTS: Integer
8
+ CRLF: String
9
+
6
10
  attr_reader pending: Array[Request]
7
11
  attr_reader requests: Array[Request]
8
12
 
9
13
  @options: Options
10
14
  @max_concurrent_requests: Integer
11
15
  @max_requests: Integer
12
- @parser: HTTP1
16
+ @parser: Parser::HTTP1
13
17
  @buffer: Buffer
14
18
 
15
19
  def interests: () -> io_interests?
@@ -30,11 +34,13 @@ module HTTPX
30
34
 
31
35
  def handle_error: (StandardError ex) -> void
32
36
 
37
+ def on_start: () -> void
38
+
33
39
  def on_headers: (Hash[String, Array[String]] headers) -> void
34
40
 
35
41
  def on_trailers: (Hash[String, Array[String]] headers) -> void
36
42
 
37
- def on_data: (string chunk) -> void
43
+ def on_data: (String chunk) -> void
38
44
 
39
45
  def on_complete: () -> void
40
46
 
@@ -42,7 +48,7 @@ module HTTPX
42
48
 
43
49
  def ping: () -> void
44
50
 
45
- def timeout: () -> Integer
51
+ def timeout: () -> Numeric
46
52
 
47
53
  private
48
54
 
@@ -54,7 +60,7 @@ module HTTPX
54
60
 
55
61
  def disable_pipelining: () -> void
56
62
 
57
- def set_protocol_headers: (Request) -> _Each[headers_key, String]
63
+ def set_protocol_headers: (Request) -> _Each[[String, String]]
58
64
 
59
65
  def headline_uri: (Request) -> String
60
66
 
@@ -64,7 +70,7 @@ module HTTPX
64
70
 
65
71
  def join_trailers: (Request request) -> void
66
72
 
67
- def join_headers2: (_Each[headers_key, String] headers) -> void
73
+ def join_headers2: (_Each[[String, String]] headers) -> void
68
74
 
69
75
  def join_body: (Request request) -> void
70
76
 
@@ -3,10 +3,13 @@ module HTTPX
3
3
  include Callbacks
4
4
  include Loggable
5
5
 
6
+ MAX_CONCURRENT_REQUESTS: Integer
7
+
6
8
  attr_reader streams: Hash[Request, HTTP2Next::Stream]
7
9
  attr_reader pending: Array[Request]
8
10
 
9
11
  @options: Options
12
+ @settings: Hash[Symbol, Integer | bool]
10
13
  @max_concurrent_requests: Integer
11
14
  @max_requests: Integer
12
15
  @drains: Hash[Request, String]
@@ -23,7 +26,7 @@ module HTTPX
23
26
 
24
27
  def <<: (String) -> void
25
28
 
26
- def can_buffer_more_requests: () -> bool
29
+ def can_buffer_more_requests?: () -> bool
27
30
 
28
31
  def send: (Request) -> void
29
32
 
@@ -35,7 +38,7 @@ module HTTPX
35
38
 
36
39
  alias reset init_connection
37
40
 
38
- def timeout: () -> Integer
41
+ def timeout: () -> Numeric
39
42
 
40
43
  private
41
44
 
@@ -45,7 +48,7 @@ module HTTPX
45
48
 
46
49
  def headline_uri: (Request) -> String
47
50
 
48
- def set_protocol_headers: (Request) -> _Each[headers_key, String]
51
+ def set_protocol_headers: (Request) -> _Each[[String, String]]
49
52
 
50
53
  def handle: (Request request, HTTP2Next::Stream stream) -> void
51
54
 
@@ -61,9 +64,11 @@ module HTTPX
61
64
 
62
65
  def on_stream_headers: (HTTP2Next::Stream stream, Request request, Array[[String, String]] headers) -> void
63
66
 
64
- def on_stream_trailers: (HTTP2Next::Stream stream, Request request, Array[[String, String]] headers) -> void
67
+ def on_stream_trailers: (HTTP2Next::Stream stream, Response response, Array[[String, String]] headers) -> void
68
+
69
+ def on_stream_data: (HTTP2Next::Stream stream, Request request, String data) -> void
65
70
 
66
- def on_stream_data: (HTTP2Next::Stream stream, Request request, string data) -> void
71
+ def on_stream_refuse: (HTTP2Next::Stream stream, Request request, StandardError error) -> void
67
72
 
68
73
  def on_stream_close: (HTTP2Next::Stream stream, Request request, (Symbol | StandardError)? error) -> void
69
74
 
@@ -74,12 +79,18 @@ module HTTPX
74
79
  def on_close: (Integer last_frame, Symbol? error, String? payload) -> void
75
80
 
76
81
  def on_frame_sent: (HTTP2Next::frame) -> void
82
+
77
83
  def on_frame_received: (HTTP2Next::frame) -> void
78
84
 
85
+ def on_altsvc: (String origin, HTTP2Next::frame) -> void
86
+
79
87
  def on_promise: (HTTP2Next::Stream) -> void
80
88
 
81
89
  def on_origin: (String) -> void
82
90
 
83
91
  def on_pong: (string ping) -> void
92
+
93
+ class Error < ::HTTPX::Error
94
+ end
84
95
  end
85
96
  end
data/sig/connection.rbs CHANGED
@@ -4,45 +4,54 @@ module HTTPX
4
4
 
5
5
  def on: (Symbol) { (*untyped) -> void } -> void
6
6
  def empty?: () -> bool
7
+ # def exhausted?: () -> bool
7
8
  def close: () -> void
8
9
  def consume: () -> void
9
10
  def <<: (string) -> void
11
+ # def send: (Request) -> void
12
+ # def ping: () -> void
13
+ # def timeout: () -> (Integer | Float)
14
+
10
15
  end
11
16
 
17
+ extend Forwardable
12
18
  include Loggable
13
19
  include Callbacks
14
- extend HTTPX::Registry[String, Class]
20
+ include HTTPX::Registry[String, Class]
21
+
22
+ BUFFER_SIZE: Integer
15
23
 
16
- attr_reader origin: generic_uri
24
+ attr_reader origin: URI::Generic
17
25
  attr_reader state: Symbol
18
26
  attr_reader pending: Array[Request]
19
- attr_reader options: options
27
+ attr_reader options: Options
28
+ attr_writer timers: untyped # Timers::Timer
20
29
 
21
30
  def addresses: () -> Array[ipaddr]?
22
31
 
23
32
  def addresses=: (Array[ipaddr]) -> void
24
33
 
25
- def match?: (generic_uri, options) -> bool
34
+ def match?: (URI::Generic, options) -> bool
26
35
 
27
36
  def mergeable?: (Connection) -> bool
28
37
 
29
38
  def coalescable?: (Connection) -> bool
30
39
 
31
- def create_idle: (options) -> Connection
32
- | () -> Connection
40
+ def create_idle: (?Hash[Symbol, untyped] options) -> Connection
33
41
 
34
42
  def merge: (Connection) -> void
35
43
 
36
44
  def purge_pending: () { (Request) -> void } -> void
37
45
 
38
- def match_altsvcs?: (generic_uri) -> bool
46
+ def match_altsvcs?: (URI::Generic uri) -> bool
39
47
 
40
48
  def connecting?: () -> bool
49
+
41
50
  def inflight?: () -> boolish
42
51
 
43
52
  def interests: () -> io_interests?
44
53
 
45
- def to_io: () -> _ToIO
54
+ def to_io: () -> IO
46
55
 
47
56
  def call: () -> void
48
57
 
@@ -55,7 +64,7 @@ module HTTPX
55
64
 
56
65
  private
57
66
 
58
- def initialize: (String, generic_uri, options) -> untyped
67
+ def initialize: (String, URI::Generic, options) -> untyped
59
68
 
60
69
  def connect: () -> void
61
70
 
@@ -76,10 +85,13 @@ module HTTPX
76
85
 
77
86
  def handle_response: () -> void
78
87
 
79
- def on_error: (StandardError) -> void
88
+ def on_error: (HTTPX::TimeoutError | Error | StandardError) -> void
80
89
 
81
90
  def handle_error: (StandardError) -> void
82
91
 
83
- def total_timeout: () -> Timers::Timer?
92
+ def total_timeout: () -> untyped?
93
+ # def total_timeout: () -> Timers::Timer?
94
+ #
95
+ def purge_after_closed: () -> void
84
96
  end
85
97
  end
data/sig/errors.rbs CHANGED
@@ -1,3 +1,37 @@
1
1
  module HTTPX
2
- Error: singleton(StandardError)
2
+ class Error < StandardError
3
+ end
4
+
5
+ class TimeoutError < Error
6
+ attr_reader timeout: Numeric
7
+
8
+ def to_connection_error: () -> ConnectTimeoutError
9
+ private
10
+
11
+ def initialize: (Numeric timeout, String message) -> untyped
12
+ end
13
+
14
+ class TotalTimeoutError < TimeoutError
15
+ end
16
+
17
+ class ConnectTimeoutError < TimeoutError
18
+ end
19
+
20
+ class SettingsTimeoutError < TimeoutError
21
+ end
22
+
23
+ class ResolveTimeoutError < TimeoutError
24
+ end
25
+
26
+ class ResolveError < Error
27
+ end
28
+
29
+ class NativeResolveError < ResolveError
30
+ attr_reader connection: Connection
31
+ attr_reader host: String
32
+
33
+ private
34
+
35
+ def initialize: (Connection connection, String hostname, ?String message) -> untyped
36
+ end
3
37
  end
data/sig/headers.rbs CHANGED
@@ -2,44 +2,45 @@ module HTTPX
2
2
  class Headers
3
3
  include _ToS
4
4
 
5
- @headers: headers_hash
5
+ EMPTY: Array[untyped]
6
6
 
7
- def self.new: (?untyped headers) -> Headers
7
+ @headers: Hash[String, Array[String]]
8
+
9
+ def self.new: (?untyped headers) -> instance
8
10
 
9
11
  def ==: (untyped other) -> bool
10
12
 
11
- def []: (headers_key field) -> _ToS?
12
- def []=: (headers_key field, headers_value value) -> void
13
+ def []: (String field) -> String?
14
+ def []=: (String field, headers_value value) -> void
13
15
 
14
- def add: (headers_key field, string value) -> void
15
- def delete: (headers_key field) -> void
16
+ def add: (String field, string value) -> void
17
+ def delete: (String field) -> Array[String]?
16
18
 
17
- def each: (?_Each[headers_key, String]? extra_headers) { (headers_key, String) -> void } -> void
18
- | (?_Each[headers_key, String]? extra_headers) -> Enumerable[[headers_key, String], void]
19
+ def each: (?_Each[[String, String]]? extra_headers) { (String k, String v) -> void } -> void
20
+ | (?_Each[[String, String]]? extra_headers) -> Enumerable[[String, String]]
19
21
 
20
- def get: (headers_key field) -> Array[String]
21
- def key?: (headers_key downcased_key) -> bool
22
+ def get: (String field) -> Array[String]
23
+ def key?: (String downcased_key) -> bool
22
24
 
23
- def merge: (_Each[headers_key, headers_value] other) -> Headers
25
+ def merge: (_Each[[String, headers_value]] other) -> Headers
24
26
 
25
27
  def same_headers?: (untyped headers) -> bool
26
28
 
27
- def to_a: () -> Array[[headers_key, String]]
28
- def to_hash: () -> Hash[headers_key, String]
29
+ def to_a: () -> Array[[String, String]]
30
+ def to_hash: () -> Hash[String, String]
29
31
  alias to_h to_hash
30
32
 
31
- def inspect: () -> String
33
+ def inspect: () -> String
32
34
 
33
35
  private
34
36
 
35
- def initialize: (headers?) -> untyped
37
+ def initialize: (?headers?) -> untyped
36
38
  def array_value: (headers_value) -> Array[String]
37
- def downcased: (headers_key) -> String
39
+ def downcased: (_ToS field) -> String
38
40
  end
39
41
 
40
- type headers_key = String | Symbol
41
42
  type headers_value = _ToS | Array[_ToS]
42
- type headers_hash = Hash[headers_key, headers_value]
43
- type headers_input = headers_hash | Array[[headers_key, string]]
43
+ type headers_hash = Hash[_ToS, headers_value]
44
+ type headers_input = headers_hash | Array[[_ToS, string]]
44
45
  type headers = Headers | headers_input
45
46
  end
data/sig/httpx.rbs CHANGED
@@ -4,12 +4,15 @@ module HTTPX
4
4
  VERSION: String
5
5
 
6
6
  type uri = URI::HTTP | URI::HTTPS | string
7
- type generic_uri = uri | URI::Generic
7
+ type generic_uri = String | URI::Generic
8
8
 
9
9
  type verb = :options | :get | :head | :post | :put | :delete | :trace | :connect |
10
10
  :propfind | :proppatch | :mkcol | :copy | :move | :lock | :unlock | :orderpatch |
11
11
  :acl | :report | :patch | :search
12
12
 
13
13
  module Plugins
14
+ def self?.load_plugin: (Symbol) -> Module
15
+
16
+ def self?.register_plugin: (Symbol, Module) -> void
14
17
  end
15
18
  end
data/sig/loggable.rbs CHANGED
@@ -4,8 +4,10 @@ module HTTPX
4
4
  end
5
5
 
6
6
  module Loggable
7
+ COLORS: Hash[Symbol, Integer]
8
+
7
9
  def log: (?level: Integer?, ?color: Symbol?) { () -> String } -> void
8
10
 
9
- def log_exception: (StandardError, **untyped) -> void
11
+ def log_exception: (Exception error, ?level: Integer, ?color: Symbol) -> void
10
12
  end
11
13
  end
data/sig/options.rbs CHANGED
@@ -4,109 +4,120 @@ module HTTPX
4
4
 
5
5
  WINDOW_SIZE: Integer
6
6
  MAX_BODY_THRESHOLD_SIZE: Integer
7
+ CONNECT_TIMEOUT: Integer
8
+ OPERATION_TIMEOUT: Integer
9
+ KEEP_ALIVE_TIMEOUT: Integer
10
+ SETTINGS_TIMEOUT: Integer
11
+ DEFAULT_OPTIONS: Hash[Symbol, untyped]
7
12
 
8
13
  type timeout_type = :connect_timeout | :settings_timeout | :operation_timeout | :keep_alive_timeout | :total_timeout
9
- type timeout = Hash[timeout_type, Numeric?]
14
+ type timeout = Hash[timeout_type, Numeric]
10
15
 
11
- def self.new: (options) -> instance
12
- | () -> instance
16
+ def self.new: (?options) -> instance
13
17
 
18
+ def self.def_option: (Symbol, ?String) -> void
19
+ | (Symbol) { (*nil) -> untyped } -> void
14
20
  # headers
15
21
  attr_reader uri: URI?
16
- def uri=: (uri) -> void
17
22
 
18
23
  # headers
19
24
  attr_reader headers: Headers?
20
- def headers=: (headers) -> void
21
25
 
22
26
  # timeout
23
27
  attr_reader timeout: timeout
24
- def timeout=: (timeout) -> void
28
+
29
+ # http2_settings
30
+ attr_reader http2_settings: Hash[Symbol, Integer | bool]
25
31
 
26
32
  # max_concurrent_requests
27
33
  attr_reader max_concurrent_requests: Integer?
28
- def max_concurrent_requests=: (Integer) -> void
29
34
 
30
35
  # max_requests
31
36
  attr_reader max_requests: Integer?
32
- def max_requests=: (Integer) -> void
33
37
 
34
38
  # window_size
35
- attr_reader window_size: int?
36
- def window_size=: (int) -> void
39
+ attr_reader window_size: Integer
37
40
 
38
41
  # body_threshold_size
39
- attr_reader body_threshold_size: int?
40
- def body_threshold_size=: (int) -> void
42
+ attr_reader body_threshold_size: Integer
41
43
 
42
44
  # transport
43
- attr_reader transport: _ToS?
44
- def transport=: (_ToS) -> void
45
+ attr_reader transport: String?
45
46
 
46
47
  # transport_options
47
48
  attr_reader transport_options: Hash[untyped, untyped]?
48
- def transport_options=: (Hash[untyped, untyped]) -> void
49
49
 
50
50
  # addresses
51
- attr_reader addresses: _ToAry[untyped]?
52
- def addresses=: (_ToAry[untyped]) -> void
51
+ attr_reader addresses: Array[ipaddr]?
53
52
 
54
53
  # params
55
54
  attr_reader params: Transcoder::urlencoded_input?
56
- def params=: (Transcoder::urlencoded_input) -> void
57
55
 
58
56
  # form
59
57
  attr_reader form: Transcoder::urlencoded_input?
60
- def form=: (Transcoder::urlencoded_input) -> void
61
58
 
62
59
  # json
63
60
  attr_reader json: _ToJson?
64
- def json=: (_ToJson) -> void
65
61
 
66
62
  # body
67
63
  attr_reader body: bodyIO?
68
- def body=: (bodyIO) -> void
64
+
65
+ # body
66
+ attr_reader origin: URI::Generic?
69
67
 
70
68
  # ssl
71
69
 
72
70
  # http2_settings
73
71
 
72
+
73
+ # classes
74
+ attr_reader connection_class: singleton(Connection)
75
+
76
+ attr_reader request_class: singleton(Request)
77
+
78
+ attr_reader response_class: singleton(Response)
79
+
80
+ attr_reader headers_class: singleton(Headers)
81
+
82
+ attr_reader request_body_class: singleton(Request::Body)
83
+
84
+ attr_reader response_body_class: singleton(Response::Body)
85
+
86
+ attr_reader ssl: Hash[Symbol, untyped]
87
+
74
88
  # request_class response_class headers_class request_body_class
75
89
  # response_body_class connection_class
76
90
  # resolver_class resolver_options
77
91
 
78
- # request_class
79
- attr_reader request_class: singleton(Request)
80
- def request_class=: (singleton(Request)) -> void
81
-
82
92
  # io
83
93
  type io_option = _ToIO | Hash[String, _ToIO]
84
94
  attr_reader io: io_option?
85
- def io=: (io_option) -> void
86
95
 
87
96
  # fallback_protocol
88
97
  attr_reader fallback_protocol: String?
89
- def fallback_protocol=: (String) -> void
90
98
 
91
99
  # debug
92
100
  attr_reader debug: _IOLogger?
93
- def debug=: (_IOLogger) -> void
94
101
 
95
102
  # debug_level
96
- attr_reader debug_level: Integer?
97
- def debug_level=: (Integer) -> void
103
+ attr_reader debug_level: Integer
98
104
 
99
105
  # persistent
100
106
  attr_reader persistent: bool?
101
- def persistent=: (bool) -> void
107
+
108
+ # resolver_options
109
+ attr_reader resolver_options: Hash[Symbol, untyped]?
102
110
 
103
111
  def ==: (untyped other) -> bool
104
- def merge: (_ToHash other) -> instance
112
+ def merge: (_ToHash[Symbol, untyped] other) -> instance
113
+ def to_hash: () -> Hash[Symbol, untyped]
105
114
 
106
115
  private
107
116
 
108
- def initialize: (options) -> untyped
117
+ REQUEST_IVARS: Array[Symbol]
118
+
119
+ def initialize: (?options options) -> untyped
109
120
  end
110
121
 
111
- type options = Options | Hash[Symbol | String, untyped]
122
+ type options = Options | Hash[Symbol, untyped]
112
123
  end