Change comparison with "None".
authorThomas Mansencal <thomas.mansencal@gmail.com>
Thu, 15 Jan 2015 20:20:23 +0000 (21:20 +0100)
committerThomas Mansencal <thomas.mansencal@gmail.com>
Thu, 15 Jan 2015 20:20:23 +0000 (21:20 +0100)
aces_1.0.0/python/aces_ocio/generateLUT.py
aces_1.0.0/python/aces_ocio/process.py

index df3cbed..53f86e1 100644 (file)
@@ -131,7 +131,7 @@ def generate1dLUTFromImage(ramp1dPath,
          Return value description.
     """
 
-    if outputPath == None:
+    if outputPath is None:
         outputPath = ramp1dPath + ".spi1d"
 
     # open image
@@ -196,7 +196,7 @@ def generate3dLUTFromImage(ramp3dPath, outputPath=None, resolution=32):
          Return value description.
     """
 
-    if outputPath == None:
+    if outputPath is None:
         outputPath = ramp3dPath + ".spi3d"
 
     args = ["--extract",
index 24fb940..527db13 100755 (executable)
@@ -190,7 +190,7 @@ class Process:
         except:\r
             try:\r
                 user = os.getenv("USERNAME")\r
-                if user == None:\r
+                if user is None:\r
                     user = os.getenv("USER")\r
             except:\r
                 user = "unknown_user"\r
@@ -438,7 +438,7 @@ class Process:
 \r
                     # This is now used to ensure that the process has finished\r
                     line = ""\r
-                    while line != None and process.poll() == None:\r
+                    while line != None and process.poll() is None:\r
                         try:\r
                             line = process.stdout.readline()\r
                         except:\r
@@ -724,7 +724,7 @@ def main():
         argsStart = len(sys.argv) + 1\r
         args = []\r
 \r
-    if cmd == None:\r
+    if cmd is None:\r
         print("process: No command specified")\r
 \r
     #\r