Open
Description
I'm doing a bit of warn-housekeeping on Hanami which uses the following (without passing a schema) to match URIs in the asset handling:
ABSOLUTE_URL_MATCHER = URI::DEFAULT_PARSER.make_regexpThis triggers the obsolescence warning since the DEFAULT_PARSER has switched to RFC3986_PARSER which just delegates make_regexp back to the RFC2396_PARSER.
Is there a recommended path forward?
URI::DEFAULT_PARSER.make_regexp--replace-with-->URI::RFC2396_PARSER.make_regexpURI::DEFAULT_PARSER.make_regexp--replace-with-->URI::RFC3986_Parser::RFC3986_URI
The warning suggest 1, but RFC2396 is obsolete, so rather 2? Or is there a third way? Thanks a lot for any hints!
(Update: Capybara uses the same URI::DEFAULT_PARSER.make_regexp as well, so the same question arises there.)
Metadata
Metadata
Assignees
Labels
No labels
Activity
MatheusRich commentedon Mar 20, 2025
I don't seem to trigger the warning when running this
ruby -W:deprecated test.rbThe warning only appears if I run
ruby -W test.rb(all warnings). Is this expected? It seems to be cause by theif $VERBOSEcheck.