Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Rack 3 support #1857

Merged
merged 29 commits into from
Jan 5, 2024
Merged
Changes from 1 commit
Commits
Show all changes
29 commits
Select commit Hold shift + click to select a range
eff32e1
Don't allow Rack 3 builds to fail
dentarg Dec 23, 2022
482b157
Add `rackup`, `rack-session` as dependencies
dentarg Dec 24, 2022
c5f9817
Remove Rack 2 jobs
dentarg Dec 24, 2022
a86a32b
Run tests for sinatra-contrib and rack-protection
dentarg Dec 24, 2022
5efc85e
Rack 3 requires all response headers to be lowercase
dentarg Dec 28, 2022
c83b7f2
`SERVER_PROTOCOL` -> `HTTP_VERSION`
dentarg Dec 28, 2022
0b4622f
Rack 3 does not allow newlines in headers
dentarg Dec 28, 2022
943cfaa
Find `RACK_SESSION_UNPACKED_COOKIE_DATA`
dentarg Dec 28, 2022
26aeec7
rack-protection tests now pass (on Ruby 2.7.7)
dentarg Dec 28, 2022
1396f08
Cookie attributes are lowercase in Rack 3
dentarg Dec 28, 2022
0a9b043
sinatra-contrib tests now pass
dentarg Dec 29, 2022
44377b2
Fix server registration
dentarg Dec 30, 2022
8e6d11c
Update routing test `handles params without a value`
dentarg Feb 9, 2023
217c5db
Restore `continue-on-error`
dentarg Feb 13, 2023
a4a786a
Depend on `rackup` and `rack-session` >=2.0.0
dentarg Feb 24, 2023
8da32a4
`Rack::File` -> `Rack::Files` again
dentarg Feb 24, 2023
c129d58
Support `text/javascript` as JavaScript MIME type
dentarg Feb 25, 2023
41d6063
`Rack::Handler` -> `Rackup::Handler`
dentarg Mar 4, 2023
5b28218
Revert "Update routing test `handles params without a value`"
dentarg May 15, 2023
d3dfc19
Update rack requirement in rack-protection gemspec
dentarg Aug 7, 2023
4ba8664
Puma 5 is not compatible with Rack 3
dentarg Aug 7, 2023
7a514e2
Test with rack head
dentarg Aug 7, 2023
a378414
Fix typo in spec description
dentarg Nov 26, 2023
e721af6
Require rack 3.0.0, not 3.0.0.beta1
dentarg Dec 23, 2023
7a16094
rack-protection depends on rack-session
dentarg Dec 23, 2023
1e37204
CI: use rack stable (Rack >= 3.0)
dentarg Jan 2, 2024
8a78d8b
Make `rackup` an optional dependency
dentarg Jan 2, 2024
1377751
Skip "without rackup" test on rack head branch
dentarg Jan 3, 2024
985625d
Fix `test_app_start_without_rackup` on JVM rubies
dentarg Jan 4, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Fix test_app_start_without_rackup on JVM rubies
truffleruby and jruby uses the childprocess with
CHILDPROCESS_POSIX_SPAWN, and when doing so, the environment variables
aren't cocered to strings until very late:
https://github.com/enkessler/childprocess/blob/v4.1.0/lib/childprocess/unix/posix_spawn_process.rb#L109-L130

On CRuby it seems symbol environment variables will overwrite any
existing (string) ones but that does not happen on JVM rubies (I've only
tested with TruffleRuby though, but JRuby builds also failed in CI)
  • Loading branch information
dentarg committed Jan 5, 2024
commit 985625df6207b2faab3c9d4e95d0b4ed0c23c257
2 changes: 1 addition & 1 deletion test/integration_start_test.rb
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ def test_app_start_without_rackup
app_file = File.join(__dir__, "integration", "simple_app.rb")
gem_file = File.join(__dir__, "integration", "gemfile_without_rackup.rb")
command = command_for(app_file)
env = { BUNDLE_GEMFILE: gem_file }
env = { "BUNDLE_GEMFILE" => gem_file }

with_process(command: command, env: env) do |process, read_io|
assert wait_for_output(read_io, /Sinatra could not start, the "rackup" gem was not found/)
Expand Down
Loading