rack 3.2.0 → 3.2.1
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 +10 -0
- data/lib/rack/events.rb +21 -6
- data/lib/rack/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: 32413bcd1f96d1cc6283491c3a7cf4b0301d9eb84d7d334895586d42981f0858
|
4
|
+
data.tar.gz: ecd4aaba754ab7de09ced1dab1efb3366242933edeb1e549aaa14cdec1ff3cfc
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: bdf1806a0951c9523e75fe5a4be2eed0536c9e313b6f6808bb0ec7c43d62d489d63f75cb1e2a2a6741468d9fd2b34bb4ff22f0f8d32b5c3a0d3271faf2b11e73
|
7
|
+
data.tar.gz: 98183f1e7637e3e9fa3a2b32908c8b00acdf294b526c413393eaff99daf6bf4e103c5501efe87fea54435747b7a782801e54dfbd89781513557ed56f047a1f1a
|
data/CHANGELOG.md
CHANGED
@@ -4,6 +4,16 @@ All notable changes to this project will be documented in this file. For info on
|
|
4
4
|
|
5
5
|
## Unreleased
|
6
6
|
|
7
|
+
## [3.2.1] -- 2025-09-02
|
8
|
+
|
9
|
+
### Added
|
10
|
+
|
11
|
+
- Add support for streaming bodies when using `Rack::Events`. ([#2375](github.com/rack/rack/pull/2375), [@unflxw](https://github.com/unflxw))
|
12
|
+
|
13
|
+
### Fixed
|
14
|
+
|
15
|
+
- Fix an issue where a `NoMethodError` would be raised when using `Rack::Events` with streaming bodies. ([#2375](github.com/rack/rack/pull/2375), [@unflxw](https://github.com/unflxw))
|
16
|
+
|
7
17
|
## [3.2.0] - 2025-07-31
|
8
18
|
|
9
19
|
This release continues Rack's evolution toward a cleaner, more efficient foundation while maintaining backward compatibility for most applications. The breaking changes primarily affect deprecated functionality, so most users should experience a smooth upgrade with improved performance and standards compliance.
|
data/lib/rack/events.rb
CHANGED
@@ -29,12 +29,13 @@ module Rack
|
|
29
29
|
#
|
30
30
|
# * on_send(request, response)
|
31
31
|
#
|
32
|
-
# The webserver has started iterating over the response body
|
33
|
-
# has started sending data over the
|
34
|
-
# a request object and the response
|
35
|
-
# constructed from the rack triple that the
|
36
|
-
# SHOULD NOT be made to the response object
|
37
|
-
# started sending data. Any mutations will
|
32
|
+
# The webserver has started iterating over the response body, or has called
|
33
|
+
# the streaming body, and presumably has started sending data over the
|
34
|
+
# wire. This method is always called with a request object and the response
|
35
|
+
# object. The response object is constructed from the rack triple that the
|
36
|
+
# application returned. Changes SHOULD NOT be made to the response object
|
37
|
+
# as the webserver has already started sending data. Any mutations will
|
38
|
+
# likely result in an exception.
|
38
39
|
#
|
39
40
|
# * on_finish(request, response)
|
40
41
|
#
|
@@ -90,6 +91,20 @@ module Rack
|
|
90
91
|
@handlers.reverse_each { |handler| handler.on_send request, response }
|
91
92
|
super
|
92
93
|
end
|
94
|
+
|
95
|
+
def call(stream)
|
96
|
+
@handlers.reverse_each { |handler| handler.on_send request, response }
|
97
|
+
super
|
98
|
+
end
|
99
|
+
|
100
|
+
def respond_to?(method_name, include_all = false)
|
101
|
+
case method_name
|
102
|
+
when :each, :call
|
103
|
+
@body.respond_to?(method_name, include_all)
|
104
|
+
else
|
105
|
+
super
|
106
|
+
end
|
107
|
+
end
|
93
108
|
end
|
94
109
|
|
95
110
|
class BufferedResponse < Rack::Response::Raw # :nodoc:
|
data/lib/rack/version.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: rack
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 3.2.
|
4
|
+
version: 3.2.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Leah Neukirchen
|
@@ -156,7 +156,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
156
156
|
- !ruby/object:Gem::Version
|
157
157
|
version: '0'
|
158
158
|
requirements: []
|
159
|
-
rubygems_version: 3.6.
|
159
|
+
rubygems_version: 3.6.9
|
160
160
|
specification_version: 4
|
161
161
|
summary: A modular Ruby webserver interface.
|
162
162
|
test_files: []
|