diff options
author | Parker Berberian <pberberian@iol.unh.edu> | 2018-11-20 11:19:55 -0500 |
---|---|---|
committer | Parker Berberian <pberberian@iol.unh.edu> | 2018-11-26 14:07:15 -0500 |
commit | b7c4d286ffa618be0e95b15f3883e2f6920a3fb1 (patch) | |
tree | 930e9b9282b8f50e671844b2a1e7f39dc5d6035d /src/workflow/snapshot_workflow.py | |
parent | 6a90796de1df8d74c79415c39c867ffe6cd80fd0 (diff) |
Fix all flake8 errors
The flake8 command in test.sh finds no longer finds any errors.
This may form a basis of a jenkins verify job as a sort of 'weak compile-time checks'
The flake8 command will not complain about line length, and will not complain about
django's manage.py file
Change-Id: Ic47cb4fc7ada55e64485661ab6881aef475018ff
Signed-off-by: Parker Berberian <pberberian@iol.unh.edu>
Diffstat (limited to 'src/workflow/snapshot_workflow.py')
-rw-r--r-- | src/workflow/snapshot_workflow.py | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/src/workflow/snapshot_workflow.py b/src/workflow/snapshot_workflow.py index 9d4b880..4ddc397 100644 --- a/src/workflow/snapshot_workflow.py +++ b/src/workflow/snapshot_workflow.py @@ -11,9 +11,11 @@ import datetime import json -from resource_inventory.models import * -from workflow.models import * -from workflow.forms import * +from booking.models import Booking +from resource_inventory.models import Host, Image +from workflow.models import WorkflowStep +from workflow.forms import SnapshotMetaForm, SnapshotHostSelectForm + class Select_Host_Step(WorkflowStep): template = "snapshot_workflow/steps/select_host.html" @@ -37,7 +39,6 @@ class Select_Host_Step(WorkflowStep): for genericHost in booking.resource.template.getHosts(): booking_hosts[booking.id]['hosts'].append({"name": genericHost.resource.name}) - context['booking_hosts'] = booking_hosts chosen_host = self.repo_get(self.repo.SNAPSHOT_MODELS, {}).get("host") @@ -77,6 +78,7 @@ class Select_Host_Step(WorkflowStep): self.metastep.set_valid("Success") return self.render(request) + class Image_Meta_Step(WorkflowStep): template = "snapshot_workflow/steps/meta.html" title = "Additional Information" @@ -88,7 +90,6 @@ class Image_Meta_Step(WorkflowStep): context['form'] = SnapshotMetaForm() return context - def post_render(self, request): form = SnapshotMetaForm(request.POST) if form.is_valid(): |