diff --git a/rhodecode/integrations/routes.py b/rhodecode/integrations/routes.py --- a/rhodecode/integrations/routes.py +++ b/rhodecode/integrations/routes.py @@ -36,7 +36,7 @@ class ValidIntegrationPredicate(object): self.val = val def text(self): - return 'valid_integration_route = %s' % self.val + return f'valid_integration_route = {self.val}' phash = text diff --git a/rhodecode/integrations/tests/test_integrations.py b/rhodecode/integrations/tests/test_integrations.py --- a/rhodecode/integrations/tests/test_integrations.py +++ b/rhodecode/integrations/tests/test_integrations.py @@ -74,7 +74,7 @@ def _post_integration_test_helper(app, u ('__end__', 'settings:mapping'), ] errors_response = app.post(url, form_data) - assert 'Errors exist' in errors_response.body + assert 'Errors exist' in errors_response.text form_data[-2] = ('test_string_field', 'data!') assert Session().query(Integration).count() == 0 diff --git a/rhodecode/integrations/types/base.py b/rhodecode/integrations/types/base.py --- a/rhodecode/integrations/types/base.py +++ b/rhodecode/integrations/types/base.py @@ -23,7 +23,9 @@ import string import collections import logging import requests -import urllib.request, urllib.parse, urllib.error +import urllib.request +import urllib.parse +import urllib.error from requests.adapters import HTTPAdapter from requests.packages.urllib3.util.retry import Retry diff --git a/rhodecode/integrations/views.py b/rhodecode/integrations/views.py --- a/rhodecode/integrations/views.py +++ b/rhodecode/integrations/views.py @@ -266,7 +266,7 @@ class IntegrationSettingsViewBase(BaseAp """ _ = self.request.translate - controls = self.request.POST.items() + controls = list(self.request.POST.items()) pstruct = peppercorn.parse(controls) if self.integration and pstruct.get('delete'):