Skip to content
Snippets Groups Projects
Commit d0b61739 authored by Campbell Barton's avatar Campbell Barton
Browse files

Cleanup: name DUPLICATE_ACCEPT for accepted duplicates

parent 8399c5ad
No related branches found
Tags
No related merge requests found
...@@ -9,7 +9,8 @@ this script updates XML themes once new settings are added ...@@ -9,7 +9,8 @@ this script updates XML themes once new settings are added
import bpy import bpy
DUPLICATE_WHITELIST = ( # These are known duplicates which do not warn.
DUPLICATE_ACCEPT = (
# operators # operators
('ACTION_OT_clean', 'GRAPH_OT_clean'), ('ACTION_OT_clean', 'GRAPH_OT_clean'),
('ACTION_OT_clickselect', 'GRAPH_OT_clickselect'), ('ACTION_OT_clickselect', 'GRAPH_OT_clickselect'),
...@@ -89,7 +90,7 @@ def check_duplicates(): ...@@ -89,7 +90,7 @@ def check_duplicates():
import rna_info import rna_info
DUPLICATE_IGNORE_FOUND = set() DUPLICATE_IGNORE_FOUND = set()
DUPLICATE_WHITELIST_FOUND = set() DUPLICATE_ACCEPT_FOUND = set()
structs, funcs, ops, props = rna_info.BuildRNAInfo() structs, funcs, ops, props = rna_info.BuildRNAInfo()
...@@ -112,18 +113,18 @@ def check_duplicates(): ...@@ -112,18 +113,18 @@ def check_duplicates():
for v, k in sort_ls: for v, k in sort_ls:
if len(v) > 1: if len(v) > 1:
if v not in DUPLICATE_WHITELIST: if v not in DUPLICATE_ACCEPT:
print("found %d: %r, \"%s\"" % (len(v), v, k)) print("found %d: %r, \"%s\"" % (len(v), v, k))
#print("%r," % (v,)) # print("%r," % (v,))
else: else:
DUPLICATE_WHITELIST_FOUND.add(v) DUPLICATE_ACCEPT_FOUND.add(v)
test = (DUPLICATE_IGNORE - DUPLICATE_IGNORE_FOUND) test = (DUPLICATE_IGNORE - DUPLICATE_IGNORE_FOUND)
if test: if test:
print("Invalid 'DUPLICATE_IGNORE': %r" % test) print("Invalid 'DUPLICATE_IGNORE': %r" % test)
test = (set(DUPLICATE_WHITELIST) - DUPLICATE_WHITELIST_FOUND) test = (set(DUPLICATE_ACCEPT) - DUPLICATE_ACCEPT_FOUND)
if test: if test:
print("Invalid 'DUPLICATE_WHITELIST': %r" % test) print("Invalid 'DUPLICATE_ACCEPT': %r" % test)
def main(): def main():
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment