scripts:Update unique error enums as of 10/31/16
No new checks this week, updated script to handle blank lines and also
to not output the API name debug info by default.
Cmd line was "python spec.py -update"
diff --git a/layers/spec.py b/layers/spec.py
index bdd306b..75b3a16 100644
--- a/layers/spec.py
+++ b/layers/spec.py
@@ -142,7 +142,7 @@
code_text_list = code_text.split()
if len(code_text_list) > 1 and code_text_list[1].startswith('vk'):
api_function = code_text_list[1].strip('(')
- print "Found API function: %s" % (api_function)
+ #print "Found API function: %s" % (api_function)
elif tag.tag == '{http://www.w3.org/1999/xhtml}div' and tag.get('class') == 'sidebar':
# parse down sidebar to check for valid usage cases
valid_usage = False
@@ -249,9 +249,9 @@
max_id = 0
with open(db_file, "r") as infile:
for line in infile:
- if line.startswith('#'):
- continue
line = line.strip()
+ if line.startswith('#') or '' == line:
+ continue
db_line = line.split(self.delimiter)
if len(db_line) != 6:
print "ERROR: Bad database line doesn't have 6 elements: %s" % (line)