Skip to content

Commit

Permalink
Fix bug in grouping code
Browse files Browse the repository at this point in the history
  • Loading branch information
mbadams5 committed Dec 17, 2020
1 parent 67387d7 commit 4774908
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions scripts/dev/generate_epJSON_schema/idd_parser.py
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,7 @@ class Data:
def parse_idd(data):
root = {'$schema': "http://json-schema.org/draft-04/schema#", 'properties': {}}
data.file_size = len(data.file)
current_group_name = None
current_group_name = '**ungrouped**'

while data.index < data.file_size:
token = look_ahead(data)
Expand All @@ -120,9 +120,7 @@ def parse_idd(data):
obj_data = parse_obj(data)
root['properties'][obj_name] = {}
root['properties'][obj_name]['patternProperties'] = {}
if current_group_name is not None:
root['properties'][obj_name]['group'] = current_group_name
current_group_name = None
root['properties'][obj_name]['group'] = current_group_name

name_pattern_properties = '.*'
if 'name' in obj_data:
Expand Down

5 comments on commit 4774908

@nrel-bot-2c
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

AddGroupToSchema (mbadams5) - x86_64-Linux-Ubuntu-18.04-gcc-7.5: OK (3029 of 3029 tests passed, 0 test warnings)

Build Badge Test Badge

@nrel-bot-2
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

AddGroupToSchema (mbadams5) - x86_64-Linux-Ubuntu-18.04-gcc-7.5-UnitTestsCoverage-Debug: OK (1555 of 1555 tests passed, 0 test warnings)

Build Badge Test Badge Coverage Badge

@nrel-bot-3
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

AddGroupToSchema (mbadams5) - x86_64-MacOS-10.15-clang-11.0.0: OK (2989 of 2989 tests passed, 0 test warnings)

Build Badge Test Badge

@nrel-bot
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

AddGroupToSchema (mbadams5) - Win64-Windows-10-VisualStudio-16: OK (2246 of 2246 tests passed, 0 test warnings)

Build Badge Test Badge

@nrel-bot-2b
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

AddGroupToSchema (mbadams5) - x86_64-Linux-Ubuntu-18.04-gcc-7.5-IntegrationCoverage-Debug: OK (721 of 721 tests passed, 0 test warnings)

Build Badge Test Badge Coverage Badge

Please sign in to comment.