Przeglądaj źródła

Fix style errors.

Jelmer Vernooij 7 lat temu
rodzic
commit
0046eb8a62
2 zmienionych plików z 4 dodań i 3 usunięć
  1. 2 2
      dulwich/objects.py
  2. 2 1
      setup.py

+ 2 - 2
dulwich/objects.py

@@ -810,8 +810,8 @@ def parse_tree(text, strict=False):
     :raise ObjectFormatException: if the object was malformed in some way
     """
     count = 0
-    l = len(text)
-    while count < l:
+    length = len(text)
+    while count < length:
         mode_end = text.index(b' ', count)
         mode_text = text[count:mode_end]
         if strict and mode_text.startswith(b'0'):

+ 2 - 1
setup.py

@@ -47,7 +47,8 @@ if sys.platform == 'darwin' and os.path.exists('/usr/bin/xcodebuild'):
     for line in out.splitlines():
         line = line.decode("utf8")
         # Also parse only first digit, because 3.2.1 can't be parsed nicely
-        if line.startswith('Xcode') and int(line.split()[1].split('.')[0]) >= 4:
+        if (line.startswith('Xcode') and
+            int(line.split()[1].split('.')[0]) >= 4):
             os.environ['ARCHFLAGS'] = ''
 
 tests_require = ['fastimport']