Last Modified
2015-07-03 09:21:05 -0400
Requires
  • uri

Description

TODO: Remove this monkey patch once ruby 1.9.3+ is the minimum supported version.

This patch backports URI#hostname to ruby 1.9.2 and older. URI#hostname is used for IPv6 support in Excon.

URI#hostname was added in stdlib in v1_9_3_0 in this commit:

https://github.com/ruby/ruby/commit/5fd45a4b79dd26f9e7b6dc41142912df911e4d7d

Addressable::URI is also an URI parser accepted in some parts of Excon. Addressable::URI#hostname was added in addressable-2.3.5+ in this commit:

https://github.com/sporkmonger/addressable/commit/1b94abbec1f914d5f707c92a10efbb9e69aab65e

Users who want to use Addressable::URI to parse URIs must upgrade to 2.3.5 or newer.