httpx 0.17.0 → 0.18.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (58) hide show
  1. checksums.yaml +4 -4
  2. data/doc/release_notes/0_18_0.md +69 -0
  3. data/lib/httpx/adapters/datadog.rb +1 -1
  4. data/lib/httpx/adapters/faraday.rb +5 -3
  5. data/lib/httpx/adapters/webmock.rb +7 -1
  6. data/lib/httpx/altsvc.rb +2 -2
  7. data/lib/httpx/chainable.rb +3 -3
  8. data/lib/httpx/connection/http1.rb +3 -3
  9. data/lib/httpx/connection/http2.rb +6 -4
  10. data/lib/httpx/connection.rb +67 -70
  11. data/lib/httpx/domain_name.rb +1 -1
  12. data/lib/httpx/extensions.rb +50 -4
  13. data/lib/httpx/io/ssl.rb +1 -1
  14. data/lib/httpx/io/tls.rb +7 -7
  15. data/lib/httpx/loggable.rb +5 -5
  16. data/lib/httpx/options.rb +7 -7
  17. data/lib/httpx/plugins/aws_sdk_authentication.rb +42 -18
  18. data/lib/httpx/plugins/aws_sigv4.rb +9 -11
  19. data/lib/httpx/plugins/compression.rb +5 -3
  20. data/lib/httpx/plugins/cookies/jar.rb +1 -1
  21. data/lib/httpx/plugins/expect.rb +7 -3
  22. data/lib/httpx/plugins/grpc/message.rb +2 -2
  23. data/lib/httpx/plugins/grpc.rb +3 -3
  24. data/lib/httpx/plugins/internal_telemetry.rb +8 -8
  25. data/lib/httpx/plugins/multipart.rb +2 -2
  26. data/lib/httpx/plugins/response_cache/store.rb +55 -0
  27. data/lib/httpx/plugins/response_cache.rb +88 -0
  28. data/lib/httpx/plugins/retries.rb +22 -3
  29. data/lib/httpx/plugins/stream.rb +1 -1
  30. data/lib/httpx/pool.rb +39 -13
  31. data/lib/httpx/request.rb +6 -6
  32. data/lib/httpx/resolver/https.rb +5 -7
  33. data/lib/httpx/resolver/native.rb +4 -2
  34. data/lib/httpx/resolver/system.rb +2 -0
  35. data/lib/httpx/resolver.rb +2 -2
  36. data/lib/httpx/response.rb +23 -14
  37. data/lib/httpx/selector.rb +5 -17
  38. data/lib/httpx/session.rb +7 -2
  39. data/lib/httpx/session2.rb +1 -1
  40. data/lib/httpx/timers.rb +84 -0
  41. data/lib/httpx/transcoder/body.rb +2 -1
  42. data/lib/httpx/transcoder/form.rb +1 -1
  43. data/lib/httpx/transcoder/json.rb +1 -1
  44. data/lib/httpx/utils.rb +8 -0
  45. data/lib/httpx/version.rb +1 -1
  46. data/lib/httpx.rb +1 -0
  47. data/sig/chainable.rbs +1 -0
  48. data/sig/connection.rbs +12 -6
  49. data/sig/plugins/aws_sdk_authentication.rbs +22 -4
  50. data/sig/plugins/response_cache.rbs +35 -0
  51. data/sig/plugins/retries.rbs +3 -0
  52. data/sig/pool.rbs +6 -0
  53. data/sig/resolver/native.rbs +3 -4
  54. data/sig/resolver/system.rbs +2 -0
  55. data/sig/response.rbs +3 -2
  56. data/sig/timers.rbs +32 -0
  57. data/sig/utils.rbs +4 -0
  58. metadata +10 -17
data/sig/utils.rbs CHANGED
@@ -4,6 +4,10 @@ module HTTPX
4
4
 
5
5
  def self?.parse_retry_after: (String) -> Numeric
6
6
 
7
+ def self?.now: () -> Numeric
8
+
9
+ def self?.elapsed_time: (Numeric monotonic_time) -> Numeric
10
+
7
11
  def self?.to_uri: (generic_uri uri) -> URI::Generic
8
12
  end
9
13
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: httpx
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.17.0
4
+ version: 0.18.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Tiago Cardoso
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2021-08-31 00:00:00.000000000 Z
11
+ date: 2021-10-02 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: http-2-next
@@ -24,20 +24,6 @@ dependencies:
24
24
  - - ">="
25
25
  - !ruby/object:Gem::Version
26
26
  version: 0.4.1
27
- - !ruby/object:Gem::Dependency
28
- name: timers
29
- requirement: !ruby/object:Gem::Requirement
30
- requirements:
31
- - - ">="
32
- - !ruby/object:Gem::Version
33
- version: '0'
34
- type: :runtime
35
- prerelease: false
36
- version_requirements: !ruby/object:Gem::Requirement
37
- requirements:
38
- - - ">="
39
- - !ruby/object:Gem::Version
40
- version: '0'
41
27
  description: A client library for making HTTP requests from Ruby.
42
28
  email:
43
29
  - cardoso_tiago@hotmail.com
@@ -76,6 +62,7 @@ extra_rdoc_files:
76
62
  - doc/release_notes/0_16_0.md
77
63
  - doc/release_notes/0_16_1.md
78
64
  - doc/release_notes/0_17_0.md
65
+ - doc/release_notes/0_18_0.md
79
66
  - doc/release_notes/0_1_0.md
80
67
  - doc/release_notes/0_2_0.md
81
68
  - doc/release_notes/0_2_1.md
@@ -131,6 +118,7 @@ files:
131
118
  - doc/release_notes/0_16_0.md
132
119
  - doc/release_notes/0_16_1.md
133
120
  - doc/release_notes/0_17_0.md
121
+ - doc/release_notes/0_18_0.md
134
122
  - doc/release_notes/0_1_0.md
135
123
  - doc/release_notes/0_2_0.md
136
124
  - doc/release_notes/0_2_1.md
@@ -214,6 +202,8 @@ files:
214
202
  - lib/httpx/plugins/proxy/ssh.rb
215
203
  - lib/httpx/plugins/push_promise.rb
216
204
  - lib/httpx/plugins/rate_limiter.rb
205
+ - lib/httpx/plugins/response_cache.rb
206
+ - lib/httpx/plugins/response_cache/store.rb
217
207
  - lib/httpx/plugins/retries.rb
218
208
  - lib/httpx/plugins/stream.rb
219
209
  - lib/httpx/plugins/upgrade.rb
@@ -232,6 +222,7 @@ files:
232
222
  - lib/httpx/selector.rb
233
223
  - lib/httpx/session.rb
234
224
  - lib/httpx/session2.rb
225
+ - lib/httpx/timers.rb
235
226
  - lib/httpx/transcoder.rb
236
227
  - lib/httpx/transcoder/body.rb
237
228
  - lib/httpx/transcoder/chunker.rb
@@ -278,6 +269,7 @@ files:
278
269
  - sig/plugins/proxy/ssh.rbs
279
270
  - sig/plugins/push_promise.rbs
280
271
  - sig/plugins/rate_limiter.rbs
272
+ - sig/plugins/response_cache.rbs
281
273
  - sig/plugins/retries.rbs
282
274
  - sig/plugins/stream.rbs
283
275
  - sig/plugins/upgrade.rbs
@@ -292,6 +284,7 @@ files:
292
284
  - sig/response.rbs
293
285
  - sig/selector.rbs
294
286
  - sig/session.rbs
287
+ - sig/timers.rbs
295
288
  - sig/transcoder.rbs
296
289
  - sig/transcoder/body.rbs
297
290
  - sig/transcoder/chunker.rbs
@@ -322,7 +315,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
322
315
  - !ruby/object:Gem::Version
323
316
  version: '0'
324
317
  requirements: []
325
- rubygems_version: 3.2.15
318
+ rubygems_version: 3.2.22
326
319
  signing_key:
327
320
  specification_version: 4
328
321
  summary: HTTPX, to the future, and beyond