Andrew Bogott has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/311486

Change subject: Pupept panel: Use "{}" to represent an empty hiera config
......................................................................

Pupept panel: Use "{}" to represent an empty hiera config

We were using "" in some cases before, which wound up unparsable
down the line.

Bug: T91990
Change-Id: I1e3886270ef5a14d1073aac7e2fa80b6271fa2ff
---
M modules/openstack/files/liberty/horizon/puppettab/puppet_config.py
1 file changed, 2 insertions(+), 1 deletion(-)


  git pull ssh://gerrit.wikimedia.org:29418/operations/puppet 
refs/changes/86/311486/1

diff --git a/modules/openstack/files/liberty/horizon/puppettab/puppet_config.py 
b/modules/openstack/files/liberty/horizon/puppettab/puppet_config.py
index a43e814..fc24d8d 100644
--- a/modules/openstack/files/liberty/horizon/puppettab/puppet_config.py
+++ b/modules/openstack/files/liberty/horizon/puppettab/puppet_config.py
@@ -53,7 +53,8 @@
                                               self.prefix)
         req = requests.get(hieraurl, verify=False)
         if req.status_code == 404:
-            self.hiera_raw = ""
+            # Missing is the same as empty
+            self.hiera_raw = "{}"
         else:
             req.raise_for_status()
             self.hiera_raw = yaml.safe_load(req.text)['hiera']

-- 
To view, visit https://gerrit.wikimedia.org/r/311486
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I1e3886270ef5a14d1073aac7e2fa80b6271fa2ff
Gerrit-PatchSet: 1
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: Andrew Bogott <abog...@wikimedia.org>

_______________________________________________
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to