diff --git a/base.cfg b/base.cfg index 3ff9311fbb..240cbcc396 100644 --- a/base.cfg +++ b/base.cfg @@ -68,7 +68,10 @@ flake8-extensions = flake8-coding flake8-debugger flake8-print - +# additional pep8/flake8 rules, see docs for details +# https://pep8.readthedocs.io/en/1.4.6/intro.html#error-codes +# - E123: closing bracket does not match indentation of opening bracket’s line +flake8-select = E123 [dependencychecker] recipe = zc.recipe.egg diff --git a/src/plone/restapi/services/content/get.py b/src/plone/restapi/services/content/get.py index fe4043fc01..29d5589740 100644 --- a/src/plone/restapi/services/content/get.py +++ b/src/plone/restapi/services/content/get.py @@ -23,5 +23,5 @@ def reply(self): data['sharing'] = { '@id': '{}/@sharing'.format(self.context.absolute_url()), 'title': 'Sharing', - } + } return data diff --git a/src/plone/restapi/services/workflow/info.py b/src/plone/restapi/services/workflow/info.py index 4b8e2063d2..ca9c94c9c6 100644 --- a/src/plone/restapi/services/workflow/info.py +++ b/src/plone/restapi/services/workflow/info.py @@ -50,7 +50,7 @@ def __call__(self, expand=False): result['workflow'].update({ 'history': json_compatible(history), 'transitions': transitions, - }) + }) return result diff --git a/src/plone/restapi/tests/test_tus.py b/src/plone/restapi/tests/test_tus.py index f6955d51d5..7380db6a41 100644 --- a/src/plone/restapi/tests/test_tus.py +++ b/src/plone/restapi/tests/test_tus.py @@ -115,7 +115,7 @@ def test_tus_post_initialization_with_metadata(self): headers={'Tus-Resumable': '1.0.0', 'Upload-Length': str(UPLOAD_LENGTH), 'Upload-Metadata': metadata} - ) + ) self.assertEqual(response.status_code, 201) uid = self.get_tus_uid_from_url(response.headers['Location']) upload = TUSUpload(uid) @@ -300,7 +300,7 @@ def test_tus_can_upload_pdf_file(self): headers={'Tus-Resumable': '1.0.0', 'Upload-Length': str(pdf_file_size), 'Upload-Metadata': metadata} - ) + ) self.assertEqual(response.status_code, 201) location = response.headers['Location'] @@ -327,7 +327,7 @@ def test_tus_can_upload_text_file(self): headers={'Tus-Resumable': '1.0.0', 'Upload-Length': str(UPLOAD_LENGTH), 'Upload-Metadata': metadata} - ) + ) self.assertEqual(response.status_code, 201) location = response.headers['Location'] @@ -359,7 +359,7 @@ def test_tus_can_replace_pdf_file(self): headers={'Tus-Resumable': '1.0.0', 'Upload-Length': str(pdf_file_size), 'Upload-Metadata': metadata} - ) + ) self.assertEqual(response.status_code, 201) location = response.headers['Location'] @@ -583,7 +583,7 @@ def test_tus_can_upload_pdf_file(self): headers={'Tus-Resumable': '1.0.0', 'Upload-Length': str(pdf_file_size), 'Upload-Metadata': metadata} - ) + ) self.assertEqual(response.status_code, 201) location = response.headers['Location'] diff --git a/versions.cfg b/versions.cfg index ff9698f22e..d0c808d45e 100644 --- a/versions.cfg +++ b/versions.cfg @@ -8,7 +8,7 @@ zc.recipe.egg = 2.0.3 # Code-analysis plone.recipe.codeanalysis = 2.2 coverage = 3.7.1 -flake8 = 2.4.0 +flake8 = 2.5.0 flake8-coding = 1.2.2