From 01b9e5690f2c2d7a3d0c729217c0cf2343227911 Mon Sep 17 00:00:00 2001 From: bsimon Date: Thu, 21 May 2015 18:58:13 +0000 Subject: Fixed problems with python 2 to 3 conversion git-svn-id: http://svn.stsci.edu/svn/ssb/stsci_python/stwcs/trunk@40220 fe389314-cf27-0410-b35b-8c050e845b92 --- lib/stwcs/wcsutil/hstwcs.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'lib/stwcs/wcsutil/hstwcs.py') diff --git a/lib/stwcs/wcsutil/hstwcs.py b/lib/stwcs/wcsutil/hstwcs.py index cb61f1c..a71c33a 100644 --- a/lib/stwcs/wcsutil/hstwcs.py +++ b/lib/stwcs/wcsutil/hstwcs.py @@ -137,7 +137,7 @@ class HSTWCS(WCS): ext=ext) self.filename = filename instrument_name = hdr0.get('INSTRUME', 'DEFAULT') - if instrument_name == 'DEFAULT' or instrument_name not in inst_mappings: + if instrument_name == 'DEFAULT' or instrument_name not in list(inst_mappings.keys()): #['IRAF/ARTDATA','',' ','N/A']: self.instrument = 'DEFAULT' else: @@ -203,7 +203,7 @@ class HSTWCS(WCS): extension header """ - if self.instrument in inst_mappings: + if self.instrument in list(inst_mappings.keys()): inst_kl = inst_mappings[self.instrument] inst_kl = instruments.__dict__[inst_kl] insobj = inst_kl(prim_hdr, ext_hdr) -- cgit