From 02db5d86c49d84ddb2e0febcd3de3e8b01fe488a Mon Sep 17 00:00:00 2001
From: Todd Dembrey <todd.dembrey@torchbox.com>
Date: Fri, 15 Dec 2017 10:32:43 +0000
Subject: [PATCH] Tidy up the config settings and fix flake8

---
 .travis.yml                           |  3 ---
 mypy.ini                              | 13 -------------
 opentech/apply/tests/test_workflow.py |  1 -
 opentech/apply/workflow.py            |  5 ++---
 setup.cfg                             |  4 ++--
 5 files changed, 4 insertions(+), 22 deletions(-)
 delete mode 100644 mypy.ini

diff --git a/.travis.yml b/.travis.yml
index f45e51808..26694aaaf 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -43,9 +43,6 @@ script:
   # Type check the project
   - mypy .
 
-  # Type check the project
-  - mypy .
-
   # Run system checks
   - python manage.py check
 
diff --git a/mypy.ini b/mypy.ini
deleted file mode 100644
index 6241fe330..000000000
--- a/mypy.ini
+++ /dev/null
@@ -1,13 +0,0 @@
-[mypy]
-show_column_numbers = True
-ignore_missing_imports = True
-
-[mypy-opentech.*]
-ignore_errors = True
-
-[mypy-opentech.apply.*]
-check_untyped_defs = True
-ignore_errors = False
-
-[mypy-opentech.apply.tests.*]
-# ignore_errors = True
\ No newline at end of file
diff --git a/opentech/apply/tests/test_workflow.py b/opentech/apply/tests/test_workflow.py
index 6548e295d..c1c4bd784 100644
--- a/opentech/apply/tests/test_workflow.py
+++ b/opentech/apply/tests/test_workflow.py
@@ -1,4 +1,3 @@
-import itertools
 from django.test import SimpleTestCase
 from django.forms import Form
 
diff --git a/opentech/apply/workflow.py b/opentech/apply/workflow.py
index adabfc81c..94883dfe4 100644
--- a/opentech/apply/workflow.py
+++ b/opentech/apply/workflow.py
@@ -10,7 +10,7 @@ class Workflow:
         self.mapping = self.build_mapping(stages)
 
     def build_mapping(self, stages: Sequence['Stage']) -> Dict[str, Tuple[int, int]]:
-        mapping:  Dict[str, Tuple[int, int]] = {}
+        mapping: Dict[str, Tuple[int, int]] = {}
         for i, stage in enumerate(stages):
             for j, phase in enumerate(stage):
                 while str(phase) in mapping:
@@ -39,8 +39,7 @@ class Workflow:
 
 class Stage(Iterable['Phase']):
     def __init__(self, name: str, form: Form, phases: Sequence['Phase'],
-                 current_phase: Union['Phase', None]=None
-    ) -> None:
+                 current_phase: Union['Phase', None]=None) -> None:
         self.name = name
         self.form = form
         for phase in phases:
diff --git a/setup.cfg b/setup.cfg
index c6e0c1562..14a4da3a3 100644
--- a/setup.cfg
+++ b/setup.cfg
@@ -10,5 +10,5 @@ check_untyped_defs = True
 ignore_errors = False
 
 [flake8]
-ignore=E501,F405
-exclude=*/migrations/*
+ ignore=E501,F405
+ exclude=*/migrations/*
\ No newline at end of file
-- 
GitLab