From ea96330bb615791de58a4f6beb6203137fe1ba35 Mon Sep 17 00:00:00 2001 From: Jay Berkenbilt Date: Mon, 31 Jan 2022 18:04:14 -0500 Subject: QPDFJob json: flatten json structure Flatten everything to make it easier to map command-line flags to json. The old structure was an illusion anyway because there was no mechanism to enforce that things were in the right place. This also helps with future flexibility. --- generate_auto_job | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'generate_auto_job') diff --git a/generate_auto_job b/generate_auto_job index 63eb4350..5993a48e 100755 --- a/generate_auto_job +++ b/generate_auto_job @@ -562,7 +562,7 @@ class Main: def generate_schema(self, data): # Check to make sure that every command-line option is - # represented either in data['json'] or data['no-json']. + # represented in data['json']. # Build a list of options that we expect. If an option appears # once, we just expect to see it once. If it appears in more @@ -578,7 +578,7 @@ class Main: else: for t in sorted(tables): expected[f'{t}.{k}'] = {**v} - options_seen = set(data['no-json']) + options_seen = set() # Walk through the json information building the schema as we # go. This verifies consistency between command-line options @@ -600,7 +600,7 @@ class Main: def validate(self, data): self.check_keys('top', data, set( - ['choices', 'options', 'no-json', 'json'])) + ['choices', 'options', 'json'])) for o in data['options']: self.check_keys('top', o, set( ['table', 'prefix', 'config', 'config_prefix', -- cgit v1.2.3-54-g00ecf