terminal-shop 3.9.1 → 3.9.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/CHANGELOG.md +22 -0
- data/README.md +1 -1
- data/lib/terminal_shop/internal/transport/pooled_net_requester.rb +7 -10
- data/lib/terminal_shop/internal/util.rb +5 -5
- data/lib/terminal_shop/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: ab7a1ea1c8de85523ff44623d41356998dd5bada3747e6efc20dd24dba4075e8
|
4
|
+
data.tar.gz: 1388a54611762d55dc85565ceffb0e9449c2463c88025084f14862aa4ef3c2c4
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 9c4c251e363b1e053a7d37393ce44218ae6f40bc876f3e51a7192361fcfaa09ff04b9659e97da304791da91a00e7e77804fb54bd440a17f699e3699d3d63b567
|
7
|
+
data.tar.gz: 8a325f17115e06bbe3a3ccf2751e03841a4cb7f310ce1fea7cf6b7f7746e160c4a23927e4b5465799e15b4796cd542d3aa28c4e7801e0f49fe21f3f91ca2d734
|
data/CHANGELOG.md
CHANGED
@@ -1,5 +1,27 @@
|
|
1
1
|
# Changelog
|
2
2
|
|
3
|
+
## 3.9.3 (2025-10-16)
|
4
|
+
|
5
|
+
Full Changelog: [v3.9.2...v3.9.3](https://github.com/terminaldotshop/terminal-sdk-ruby/compare/v3.9.2...v3.9.3)
|
6
|
+
|
7
|
+
### Bug Fixes
|
8
|
+
|
9
|
+
* absolutely qualified uris should always override the default ([a277185](https://github.com/terminaldotshop/terminal-sdk-ruby/commit/a2771859a9a3931bed9854d2eea945070ea7fe13))
|
10
|
+
|
11
|
+
## 3.9.2 (2025-10-15)
|
12
|
+
|
13
|
+
Full Changelog: [v3.9.1...v3.9.2](https://github.com/terminaldotshop/terminal-sdk-ruby/compare/v3.9.1...v3.9.2)
|
14
|
+
|
15
|
+
### Bug Fixes
|
16
|
+
|
17
|
+
* coroutine leaks from connection pool ([609da82](https://github.com/terminaldotshop/terminal-sdk-ruby/commit/609da8210e3c355913e5464b72b4bf562e984024))
|
18
|
+
* should not reuse buffers for `IO.copy_stream` interop ([51cbae7](https://github.com/terminaldotshop/terminal-sdk-ruby/commit/51cbae7450fb445d494a6e8a1161ab2c87a980f6))
|
19
|
+
|
20
|
+
|
21
|
+
### Chores
|
22
|
+
|
23
|
+
* ignore linter error for tests having large collections ([6d41fa1](https://github.com/terminaldotshop/terminal-sdk-ruby/commit/6d41fa1ca081d582e52a432a2d953952bf6d15f1))
|
24
|
+
|
3
25
|
## 3.9.1 (2025-09-30)
|
4
26
|
|
5
27
|
Full Changelog: [v3.9.0...v3.9.1](https://github.com/terminaldotshop/terminal-sdk-ruby/compare/v3.9.0...v3.9.1)
|
data/README.md
CHANGED
@@ -134,9 +134,9 @@ module TerminalShop
|
|
134
134
|
|
135
135
|
# rubocop:disable Metrics/BlockLength
|
136
136
|
enum = Enumerator.new do |y|
|
137
|
-
|
138
|
-
next if finished
|
137
|
+
next if finished
|
139
138
|
|
139
|
+
with_pool(url, deadline: deadline) do |conn|
|
140
140
|
req, closing = self.class.build_request(request) do
|
141
141
|
self.class.calibrate_socket_timeout(conn, deadline)
|
142
142
|
end
|
@@ -149,7 +149,7 @@ module TerminalShop
|
|
149
149
|
|
150
150
|
self.class.calibrate_socket_timeout(conn, deadline)
|
151
151
|
conn.request(req) do |rsp|
|
152
|
-
y << [
|
152
|
+
y << [req, rsp]
|
153
153
|
break if finished
|
154
154
|
|
155
155
|
rsp.read_body do |bytes|
|
@@ -160,6 +160,8 @@ module TerminalShop
|
|
160
160
|
end
|
161
161
|
eof = true
|
162
162
|
end
|
163
|
+
ensure
|
164
|
+
conn.finish if !eof && conn&.started?
|
163
165
|
end
|
164
166
|
rescue Timeout::Error
|
165
167
|
raise TerminalShop::Errors::APITimeoutError.new(url: url, request: req)
|
@@ -168,16 +170,11 @@ module TerminalShop
|
|
168
170
|
end
|
169
171
|
# rubocop:enable Metrics/BlockLength
|
170
172
|
|
171
|
-
|
173
|
+
_, response = enum.next
|
172
174
|
body = TerminalShop::Internal::Util.fused_enum(enum, external: true) do
|
173
175
|
finished = true
|
174
|
-
|
175
|
-
enum.next
|
176
|
-
rescue StopIteration
|
177
|
-
nil
|
178
|
-
end
|
176
|
+
loop { enum.next }
|
179
177
|
ensure
|
180
|
-
conn.finish if !eof && conn&.started?
|
181
178
|
closing&.call
|
182
179
|
end
|
183
180
|
[Integer(response.code), response, body]
|
@@ -346,8 +346,9 @@ module TerminalShop
|
|
346
346
|
base_path, base_query = lhs.fetch_values(:path, :query)
|
347
347
|
slashed = base_path.end_with?("/") ? base_path : "#{base_path}/"
|
348
348
|
|
349
|
-
|
350
|
-
|
349
|
+
merged = {**parse_uri(rhs.fetch(:path)), **rhs.except(:path, :query)}
|
350
|
+
parsed_path, parsed_query = merged.fetch_values(:path, :query)
|
351
|
+
override = URI::Generic.build(**merged.slice(:scheme, :host, :port), path: parsed_path)
|
351
352
|
|
352
353
|
joined = URI.join(URI::Generic.build(lhs.except(:path, :query)), slashed, override)
|
353
354
|
query = deep_merge(
|
@@ -473,10 +474,9 @@ module TerminalShop
|
|
473
474
|
# @return [Enumerable<String>]
|
474
475
|
def writable_enum(&blk)
|
475
476
|
Enumerator.new do |y|
|
476
|
-
buf = String.new
|
477
477
|
y.define_singleton_method(:write) do
|
478
|
-
self <<
|
479
|
-
|
478
|
+
self << _1.dup
|
479
|
+
_1.bytesize
|
480
480
|
end
|
481
481
|
|
482
482
|
blk.call(y)
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: terminal-shop
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 3.9.
|
4
|
+
version: 3.9.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Terminal
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2025-
|
11
|
+
date: 2025-10-16 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: connection_pool
|