From bc71133df61cdfc0f0d113868655136fd8f813e7 Mon Sep 17 00:00:00 2001 From: sienkiew Date: Thu, 15 Sep 2011 13:46:28 +0000 Subject: fix except..as git-svn-id: http://svn.stsci.edu/svn/ssb/stsci_python/stsci_python/trunk/stwcs@13787 fe389314-cf27-0410-b35b-8c050e845b92 --- lib/stwcs/wcsutil/headerlet.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'lib/stwcs/wcsutil/headerlet.py') diff --git a/lib/stwcs/wcsutil/headerlet.py b/lib/stwcs/wcsutil/headerlet.py index 20fc86f..a18d254 100644 --- a/lib/stwcs/wcsutil/headerlet.py +++ b/lib/stwcs/wcsutil/headerlet.py @@ -248,7 +248,7 @@ def create_headerlet(fname, sciext=None, hdrname=None, destim=None, wcskey=" ", wname = "".join(["WCSNAME",wcskey.upper()]) try: wcsname = fobj[1].header[wname] - except KeyError as detail: + except KeyError, detail: message = "Missing required keyword 'WCSNAME'." module_logger.critical(message) print message, detail -- cgit