Skip to content

Commit

Permalink
Merge pull request #96 from crcresearch/develop
Browse files Browse the repository at this point in the history
Develop -> Master
  • Loading branch information
branks42 authored Jul 1, 2021
2 parents abba350 + 22daa7c commit a94b858
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 13 deletions.
23 changes: 12 additions & 11 deletions django_workflow_system/models/step_user_input.py
Original file line number Diff line number Diff line change
Expand Up @@ -63,17 +63,18 @@ def clean_fields(self, exclude=None):
# Need to ensure that if correctInput is true, that inputRequired is also true.
# No guarantee that all schemas will have these, so this is just a basic check
# for what we know currently exists
if set(['correctInputRequired', 'inputRequired']).issubset(self.specification['meta'].keys()):
# Make sure that if input isn't required that it doesn't have to be correct
if not self.specification['meta']['inputRequired'] and self.specification['meta']['correctInputRequired']:
raise ValidationError(
{
"specification": (
"There is something wrong in your specification definition. "
"Details: Inside `meta`, correctInputRequired can't be true if inputRequired is false"
)
}
)
if 'meta' in self.specification.keys():
if set(['correctInputRequired', 'inputRequired']).issubset(self.specification['meta'].keys()):
# Make sure that if input isn't required that it doesn't have to be correct
if not self.specification['meta']['inputRequired'] and self.specification['meta']['correctInputRequired']:
raise ValidationError(
{
"specification": (
"There is something wrong in your specification definition. "
"Details: Inside `meta`, correctInputRequired can't be true if inputRequired is false"
)
}
)

@property
def response_schema(self):
Expand Down
2 changes: 1 addition & 1 deletion setup.cfg
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[metadata]
name = django-workflow-system
version = 0.8.8
version = 0.8.9
description = A highly customizable workflow system for Django. Create surveys, activities, etc.
description-file = README.md
long_description_content_type = text/markdown
Expand Down
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ def read(f):

setup(
name="django-workflow-system",
version="0.8.8",
version="0.8.9",
description="A highly customizable workflow system for Django. Create surveys, activities, etc.",
long_description=read("README.md"),
long_description_content_type="text/markdown",
Expand Down

0 comments on commit a94b858

Please sign in to comment.