]> git-server-git.apps.pok.os.sepia.ceph.com Git - teuthology.git/commitdiff
In the case of invalid os_* args, give suggestions
authorZack Cerza <zack@redhat.com>
Fri, 29 May 2015 15:57:24 +0000 (09:57 -0600)
committerZack Cerza <zack@redhat.com>
Fri, 29 May 2015 15:57:24 +0000 (09:57 -0600)
http://tracker.ceph.com/issues/11813

Signed-off-by: Zack Cerza <zack@redhat.com>
teuthology/lock.py

index 9b0b37999362157c9e1f757d4c7e9c0c7ea0de9b..48d295151a8788d34f4d5c21c7e1c212dec4a4bd 100644 (file)
@@ -78,11 +78,17 @@ def vps_version_or_type_valid(machine_type, os_type, os_version):
         return True
     valid_os_and_version = get_distro_from_downburst()
     if os_type not in valid_os_and_version:
-        log.error("os-type '%s' is invalid", os_type)
+        log.error("os-type '%s' is invalid. Try one of: %s",
+                  os_type,
+                  ', '.join(valid_os_and_version.keys()))
         return False
     if not validate_distro_version(os_version,
                                    valid_os_and_version[os_type]):
-        log.error("os-version '%s' is invalid", os_version)
+        log.error(
+            "os-version '%s' is invalid for os-type '%s'. Try one of: %s",
+            os_version,
+            os_type,
+            ', '.join(valid_os_and_version[os_type]))
         return False
     return True