Bug 1344844 - Enable flake8 rule E222: "multiple spaces after operator". r?dexter draft
authorFederico Padua <federico_padua@yahoo.it>
Tue, 14 Mar 2017 01:44:29 +0100
changeset 500251 7e5ab33694bac07a5fd665cdbb00162a0f74b2bf
parent 500240 39607304b774591fa6e32c4b06158d869483c312
child 549580 ca6ddef2d970fd39f79eacb9cfb5478fb4c1096f
push id49659
push userbmo:federico_padua@yahoo.it
push dateThu, 16 Mar 2017 21:37:03 +0000
reviewersdexter
bugs1344844
milestone55.0a1
Bug 1344844 - Enable flake8 rule E222: "multiple spaces after operator". r?dexter This patch enables flake8 rule E222: "multiple spaces after operator" in toolkit/components/telemetry by removing the relative E222 entry from toolkit/components/telemetry/.flake8 and fixing the files for which the E222 error was reported. Precisely 1 error violating E222 rule was found and solved. MozReview-Commit-ID: 3xx09jkVu3E
toolkit/components/telemetry/.flake8
toolkit/components/telemetry/parse_scalars.py
--- a/toolkit/components/telemetry/.flake8
+++ b/toolkit/components/telemetry/.flake8
@@ -1,5 +1,5 @@
 [flake8]
 # See http://pep8.readthedocs.io/en/latest/intro.html#configuration
-ignore = E121, E123, E126, E129, E133, E226, E241, E242, E704, W503, E402, E128, E501, E713, E222, E202, W602, E127, W601
+ignore = E121, E123, E126, E129, E133, E226, E241, E242, E704, W503, E402, E128, E501, E713, E202, W602, E127, W601
 max-line-length = 99
 filename = *.py, +.lint
--- a/toolkit/components/telemetry/parse_scalars.py
+++ b/toolkit/components/telemetry/parse_scalars.py
@@ -231,17 +231,17 @@ class ScalarType:
     def dataset(self):
         """Get the nsITelemetry constant equivalent to the chose release channel collection
         policy for the scalar.
         """
         # The collection policy is optional, but we still define a default
         # behaviour for it.
         release_channel_collection = \
             self._definition.get('release_channel_collection', 'opt-in')
-        return 'nsITelemetry::' +  ('DATASET_RELEASE_CHANNEL_OPTOUT'
+        return 'nsITelemetry::' + ('DATASET_RELEASE_CHANNEL_OPTOUT'
             if release_channel_collection == 'opt-out' else 'DATASET_RELEASE_CHANNEL_OPTIN')
 
     @property
     def cpp_guard(self):
         """Get the cpp guard for this scalar"""
         return self._definition.get('cpp_guard')