End of Life Ruby 3.0 has reached end of life and gets no more fixes. Switch to Ruby 4.0 →
class method
Net::HTTPResponse.read_status_line
read_status_line(sock)
lib/net/http/response.rb
View on GitHub ↗
# File tmp/rubies/ruby-3.0.5/lib/net/http/response.rb, line 41
def read_status_line(sock)
str = sock.readline
m = /\AHTTP(?:\/(\d+\.\d+))?\s+(\d\d\d)(?:\s+(.*))?\z/in.match(str) or
raise Net::HTTPBadResponse, "wrong status line: #{str.dump}"
m.captures
end
No documentation available