diff --git a/bilby/gw/utils.py b/bilby/gw/utils.py
index 43520d01d6e2736bcf1a1a454ba10b1a374579fc..69b78cc6941038dafe56ce6525a05602d06a9373 100644
--- a/bilby/gw/utils.py
+++ b/bilby/gw/utils.py
@@ -491,7 +491,7 @@ def gracedb_to_json(gracedb, outdir=None):
         outfilepath = os.path.join(outdir, '{}.json'.format(gracedb))
         logger.info('Writing candidate to {}'.format(outfilepath))
         with open(outfilepath, 'w') as outfile:
-                json.dump(json_output, outfile, indent=2)
+            json.dump(json_output, outfile, indent=2)
 
     return json_output
 
@@ -528,7 +528,7 @@ def gw_data_find(observatory, gps_start_time, duration, calibration,
 
     if query_type is None:
         logger.warning('No query type provided. This may prevent data from being read.')
-        if observatory_code is 'V':
+        if observatory_code == 'V':
             query_type = 'V1Online'
         else:
             query_type = '{}_HOFT_C0{}'.format(observatory, calibration)
diff --git a/setup.py b/setup.py
index 62990546d131f81ecc20e4f6283dbe2925b886dd..9e1dc01e76cbab54466368b046f7846dee1e9671 100644
--- a/setup.py
+++ b/setup.py
@@ -46,7 +46,7 @@ def get_long_description():
     """ Finds the README and reads in the description """
     here = os.path.abspath(os.path.dirname(__file__))
     with open(os.path.join(here, 'README.rst')) as f:
-            long_description = f.read()
+        long_description = f.read()
     return long_description