Closed
Description
Hello, I think we might have a regression from this PR #1606.
With Rack 2.1.4.3 (Rack 3.X also works as expected)
irb(main):001:0> r = Rack::Request.new({"HTTP_HOST" => "some_service:3001"})
irb(main):002:0> r.host
=> "some_service"
irb(main):003:0> r.port
=> 3001
With Rack 2.2.6.4 (But any version at 2.2.X will behave the same way)
irb(main):001:0> r = Rack::Request.new({ "HTTP_HOST" => "some_service:3001" })
irb(main):002:0> r.host
=> "http://some_service:3001"
irb(main):003:0> r.port
=> nil
Am I missing something here?
Ruby: 2.7.8
Rails 7.0.4
Metadata
Assignees
Labels
No labels