Skip to content

constant URI::HOST not defined (NameError) #134

Closed

Description

@MarioRuiz

URI v 1.0.1
When already defined the constant HOST getting the error
constant URI::HOST not defined (NameError)

To reproduce this issue:

HOST = "http://www.ruby-lang.org/ja/"
require "uri"
uri = URI.parse(HOST)
puts uri.host

output:

/gems/3.2.0/gems/uri-1.0.1/lib/uri/common.rb:42:in `remove_const': constant URI::HOST not defined (NameError)

      remove_const(sym) if const_defined?(sym)

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions