Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[project]
name = "Gen3SchemaDev"
version = "2.3.2"
version = "2.3.3"
description = "Tool for data modelling in Gen3"
authors = [
{name = "JoshuaHarris391",email = "[email protected]"}
Expand Down
9 changes: 9 additions & 0 deletions src/gen3schemadev/validators/rule_validator.py
Original file line number Diff line number Diff line change
Expand Up @@ -129,6 +129,15 @@ def _system_props(self):
return system_props

def props_cannot_be_system_props(self):

if self.schema.get('id', '') == 'project':
logger.info("Skipping system property check for project schema.")
return True

if self.schema.get('id', '') == 'program':
logger.info("Skipping system property check for program schema.")
return True

props = self._get_props()
prop_keys = list(props.keys())
schema_id = self.schema.get("id", "<unknown id>")
Expand Down
23 changes: 11 additions & 12 deletions tests/test_converter.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@ def test_get_node_names(fixture_input_yaml_pass):
node_names = get_node_names(fixture_input_yaml_pass)
assert 'lipidomics_file' in node_names
assert 'sample' in node_names
assert 'project' in node_names
assert 'assay' in node_names

def test_get_node_data(fixture_input_yaml_pass):
Expand Down Expand Up @@ -214,22 +213,22 @@ def test_create_link_prop():


def test_get_properties(fixture_input_yaml_pass):
result = get_properties("project", fixture_input_yaml_pass)
result = get_properties("lipidomics_file", fixture_input_yaml_pass)
expected = [
{
'project_id': {
'type': 'string',
'description': 'Synthetic_Dataset_1',
'required': True,
'enums': None
"cv": {
"type": "number",
"description": "Coefficient of variation (%)",
"enums": None,
"required": True
}
},
{
'description': {
'type': 'string',
'description': 'Project containing synthetic data',
'required': False,
'enums': None
"lipid_species": {
"type": "array",
"enums": None,
"description": "List of lipid species",
"required": False
}
}
]
Expand Down