From 4882fb05bb6eb901d0648802b971e1732a5f6503 Mon Sep 17 00:00:00 2001 From: Lance Albertson Date: Mon, 21 Sep 2020 10:51:14 -0700 Subject: [PATCH] Workaround issue with >= 16.5 when requiring `addressable/uri` A change made in 16.5 causes an issue when trying to require `addressable/uri`. This has been filed upstream with this issue [1]. As a workaround, it seems using `autoload` fixes the problem. [1] https://github.com/chef/chef/issues/10452 Change-Id: Iae337a8ff1784c46e8171fc54eb00ef28f11561a Depends-On: https://review.opendev.org/753102 Signed-off-by: Lance Albertson --- libraries/uri.rb | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/libraries/uri.rb b/libraries/uri.rb index dbfee92f..d8b31ef6 100644 --- a/libraries/uri.rb +++ b/libraries/uri.rb @@ -20,7 +20,9 @@ # require 'uri' -require 'addressable/uri' +# TODO(ramereth): Workaround for this issue https://github.com/chef/chef/issues/10452 +# require 'addressable/uri' +autoload :Addressable, 'addressable/uri' # URI methods module ::Openstack