Index: src/sas/sascalc/dataloader/readers/sesans_reader.py
===================================================================
--- src/sas/sascalc/dataloader/readers/sesans_reader.py	(revision ecc8d1a89e96b69cb191bb9d49777ef77087764e)
+++ src/sas/sascalc/dataloader/readers/sesans_reader.py	(revision def97a02dd4532d3ab41da9ef2778f4675d92d64)
@@ -18,24 +18,22 @@
 _ZERO = 1e-16
 
+
 class Reader:
     """
     Class to load sesans files (6 columns).
     """
-    ## File type
+    # File type
     type_name = "SESANS"
 
-    ## Wildcards
+    # Wildcards
     type = ["SESANS files (*.ses)|*.ses",
             "SESANS files (*..sesans)|*.sesans"]
-    ## List of allowed extensions
+    # List of allowed extensions
     ext = ['.ses', '.SES', '.sesans', '.SESANS']
 
-    ## Flag to bypass extension check
+    # Flag to bypass extension check
     allow_all = True
 
     def read(self, path):
-
-#        print "reader triggered"
-
         """
         Load data file
@@ -79,43 +77,45 @@
                     if lam_unit == "AA":
                         lam_unit = "A"
-                    p_unit = headers["polarisation"]
 
-                    x, x_unit = self._unit_conversion(x, lam_unit,
-                                                      _fetch_unit(headers,
-                                                                  "spin echo length"))
-                    dx, dx_unit = self._unit_conversion(dx, lam_unit,
-                                                        _fetch_unit(headers,
-                                                                    "error SEL"))
-                    dlam, dlam_unit = self._unit_conversion(dlam, lam_unit,
-                                                            _fetch_unit(headers,
-                                                                        "error wavelength"))
+                    x, x_unit = self._unit_conversion(
+                        x, lam_unit,
+                        _fetch_unit(headers, "spin echo length"))
+                    dx, dx_unit = self._unit_conversion(
+                        dx, lam_unit,
+                        _fetch_unit(headers, "error SEL"))
+                    dlam, dlam_unit = self._unit_conversion(
+                        dlam, lam_unit,
+                        _fetch_unit(headers, "error wavelength"))
                     y_unit = r'\AA^{-2} cm^{-1}'
 
-                    output = Data1D(x=x, y=y, lam=lam, dy = dy, dx=dx, dlam=dlam, isSesans=True)
+                    output = Data1D(x=x, y=y, lam=lam, dy=dy, dx=dx, dlam=dlam,
+                                    isSesans=True)
                     self.filename = output.filename = basename
                     output.xaxis(r"\rm{z}", x_unit)
-                    output.yaxis(r"\rm{ln(P)/(t \lambda^2)}", y_unit)  # Adjust label to ln P/(lam^2 t), remove lam column refs
+                    # Adjust label to ln P/(lam^2 t), remove lam column refs
+                    output.yaxis(r"\rm{ln(P)/(t \lambda^2)}", y_unit)
                     # Store loading process information
                     output.meta_data['loader'] = self.type_name
-                    #output.sample.thickness = float(paramvals[6])
                     output.sample.name = params["Sample"]
                     output.sample.ID = params["DataFileTitle"]
 
-                    output.sample.zacceptance = (float(_header_fetch(params, "Q_zmax")),
-                                                 _fetch_unit(params, "Q_zmax"))
+                    output.sample.zacceptance = (
+                        float(_header_fetch(params, "Q_zmax")),
+                        _fetch_unit(params, "Q_zmax"))
 
-                    output.sample.yacceptance = (float(_header_fetch(params, "Q_ymax")),
-                                                 _fetch_unit(params, "Q_ymax"))
+                    output.sample.yacceptance = (
+                        float(_header_fetch(params, "Q_ymax")),
+                        _fetch_unit(params, "Q_ymax"))
 
                 if len(output.x) < 1:
-                    raise RuntimeError, "%s is empty" % path
+                    raise RuntimeError("%s is empty" % path)
                 return output
 
         else:
-            raise RuntimeError, "%s is not a file" % path
+            raise RuntimeError("%s is not a file" % path)
         return None
 
     def _unit_conversion(self, value, value_unit, default_unit):
-        if has_converter == True and value_unit != default_unit:
+        if has_converter and value_unit != default_unit:
             data_conv_q = Converter(value_unit)
             value = data_conv_q(value, units=default_unit)
@@ -131,4 +131,5 @@
     return headers[index]
 
+
 def _fetch_unit(params, key):
     index = [k for k in params.keys()
