]> Frank Brehm's Git Trees - pixelpark/puppetmaster-webhooks.git/commitdiff
Bugfixing in lib/webhooks/get_forge_modules.py
authorFrank Brehm <frank.brehm@pixelpark.com>
Tue, 26 Feb 2019 15:15:27 +0000 (16:15 +0100)
committerFrank Brehm <frank.brehm@pixelpark.com>
Tue, 26 Feb 2019 15:15:27 +0000 (16:15 +0100)
lib/webhooks/get_forge_modules.py

index 41e1fcf10199d42c022fe4ee40ed411030ef3e23..f14c2fa6c152da5dd5b373361628f6877b0c927c 100644 (file)
@@ -262,12 +262,15 @@ class GetForgeModulesApp(BaseHookApp):
     # -------------------------------------------------------------------------
     def get_forge_module_info(self, full_name):
 
-        release_info = ForgeModuleInfo.get_from_forge(
+        module_info = ForgeModuleInfo.get_from_forge(
             full_name, forge_uri=self.forge_uri, http_timeout=self.http_timeout,
             appname=self.appname, verbose=self.verbose, base_dir=self.base_dir, )
 
-        if self.verbose > 2:
-            LOG.debug(_("Got module info from Forge:") + '\n' + pp(release_info.as_dict()))
+        if module_info:
+            if self.verbose > 2:
+                LOG.debug(_("Got module info from Forge:") + '\n' + pp(module_info.as_dict()))
+        else:
+            LOG.warn(_("Got no module info for {!r} from Forge.").format(full_name))
 
 #        module_info = self.modules[full_name]
 #