Parcourir la source

Small PEP8 corrections

Jeroen il y a 11 ans
Parent
commit
ca8cb4c528
3 fichiers modifiés avec 12 ajouts et 6 suppressions
  1. 1 0
      borg.py
  2. 10 6
      catalog.py
  3. 1 0
      graph_search.py

+ 1 - 0
borg.py

@@ -1,6 +1,7 @@
 #!/usr/bin/env python
 # -*- coding: utf-8 -*-
 
+
 class Borg:
     __shared_state = {}
 

+ 10 - 6
catalog.py

@@ -2,22 +2,26 @@
 # -*- coding: utf-8 -*-
 
 """
-A class that uses different static function depending of a parameter passed in init
-Note the use of a single dictionnary instead of multiple conditions
+A class that uses different static function depending of a parameter passed in
+init. Note the use of a single dictionnary instead of multiple conditions
 """
 __author__ = "Ibrahim Diop <http://ibrahim.zinaria.com>"
 __gist__ = "<https://gist.github.com/diopib/7679559>"
 
+
 class Catalog():
     """
-    catalog of multiple static methods that are executed depending on an init parameter
+    catalog of multiple static methods that are executed depending on an init
+    parameter
     """
 
     def __init__(self, param):
 
-        # dictionary that will be used to determine which static method is to be executed but
-        # that will be also used to store possible param value
-        self.static_method_choices = {'param_value_1': self.static_method_1, 'param_value_2': self.static_method_2}
+        # dictionary that will be used to determine which static method is
+        # to be executed but that will be also used to store possible param
+        # value
+        self.static_method_choices = {'param_value_1': self.static_method_1,
+                                      'param_value_2': self.static_method_2}
 
         # simple test to validate param value
         if param in self.static_method_choices.keys():

+ 1 - 0
graph_search.py

@@ -1,6 +1,7 @@
 #!/usr/bin/env python
 # -*- coding: utf-8 -*-
 
+
 class GraphSearch:
     """Graph search emulation in python, from source
     http://www.python.org/doc/essays/graphs/"""