[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

[tor-commits] [stem/master] Fix parentheses indentation



commit 91299f02ee4643e626c50bdb85712a1c6f7e972f
Author: Damian Johnson <atagar@xxxxxxxxxxxxxx>
Date:   Sun Mar 12 14:58:15 2017 -0700

    Fix parentheses indentation
    
    Interesting. Older pycodestyle version on my netbook caught a minor issue my
    desktop didn't. Oh well, it's minor - parentheses indentation was off a tad.
---
 stem/descriptor/certificate.py      | 4 ++--
 test/unit/descriptor/certificate.py | 8 ++++----
 2 files changed, 6 insertions(+), 6 deletions(-)

diff --git a/stem/descriptor/certificate.py b/stem/descriptor/certificate.py
index 09cf1cf..528d594 100644
--- a/stem/descriptor/certificate.py
+++ b/stem/descriptor/certificate.py
@@ -76,9 +76,9 @@ def _parse_certificate(raw_contents, master_key_bytes, validate = False):
       # Ed25519 authentication signed with ed25519 signing key
       pass
     else:
-      raise ValueError("Unknown Certificate type %s" % binascii.hexlify(cert_type))
+      raise ValueError('Unknown Certificate type %s' % binascii.hexlify(cert_type))
   else:
-    raise ValueError("Unknown Certificate version %s" % binascii.hexlify(version))
+    raise ValueError('Unknown Certificate version %s' % binascii.hexlify(version))
 
 
 def _parse_extensions(raw_contents):
diff --git a/test/unit/descriptor/certificate.py b/test/unit/descriptor/certificate.py
index 4e71e84..0603a32 100644
--- a/test/unit/descriptor/certificate.py
+++ b/test/unit/descriptor/certificate.py
@@ -42,7 +42,7 @@ class TestCertificate(unittest.TestCase):
       'Certificate contained truncated extension',
       stem.descriptor.certificate._parse_extensions,
       stem.util.str_tools._to_bytes(cert_bytes)
-     )
+    )
 
   def test_parse_extensions_invalid_certificate_extension_type(self):
     cert_bytes = '\x00' * 39  # First 40 bytes are standard fields
@@ -56,7 +56,7 @@ class TestCertificate(unittest.TestCase):
       'Invalid certificate extension type:',
       stem.descriptor.certificate._parse_extensions,
       stem.util.str_tools._to_bytes(cert_bytes)
-     )
+    )
 
   def test_parse_extensions_invalid_n_extensions_count(self):
     cert_bytes = '\x00' * 39  # First 40 bytes are standard fields
@@ -71,7 +71,7 @@ class TestCertificate(unittest.TestCase):
       'n_extensions was 2 but parsed 1',
       stem.descriptor.certificate._parse_extensions,
       stem.util.str_tools._to_bytes(cert_bytes)
-     )
+    )
 
   def test_ed25519_key_certificate_without_extensions(self):
     cert_bytes = '\x01\x04' + '\x00' * 37  # First 40 bytes are standard fields
@@ -85,7 +85,7 @@ class TestCertificate(unittest.TestCase):
       stem.util.str_tools._to_bytes(cert_bytes),
       None,
       validate = True
-     )
+    )
 
   def test_certificate_with_invalid_signature(self):
     if not stem.prereq._is_pynacl_available():



_______________________________________________
tor-commits mailing list
tor-commits@xxxxxxxxxxxxxxxxxxxx
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-commits