[PATCH 3/6] scripts: apibuild: Improve error when API is missing from symbol file

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Improve:

 KeyError: 'virAdmConnectSetDaemonTimeout'

to

 Exception: Missing symbol file entry for 'virAdmConnectSetDaemonTimeout'

Signed-off-by: Peter Krempa <pkrempa@xxxxxxxxxx>
---
 scripts/apibuild.py | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/scripts/apibuild.py b/scripts/apibuild.py
index 23a66734ac..c232b4e2c8 100755
--- a/scripts/apibuild.py
+++ b/scripts/apibuild.py
@@ -2405,6 +2405,8 @@ class docBuilder:

         # NB: this is consumed by a regex in 'getAPIFilenames' in hvsupport.pl
         if id.type == "function":
+            if name not in self.versions:
+                raise Exception("Missing symbol file entry for '%s'" % name)
             ver = self.versions[name]
             if ver is None:
                 raise Exception("Missing version for '%s'" % name)
-- 
2.36.1




[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]

  Powered by Linux