Use Python 3.x compatible except construct

Use except x as y:, which works with any
Python version >= 2.6

Change-Id: Ibf0f9aa8fb9725c1c9c00558ec217db96301678f
This commit is contained in:
Dirk Mueller 2013-06-18 21:09:19 +02:00
parent 317220858e
commit 646096aa11

View File

@ -76,7 +76,7 @@ class SchedulerOptions(object):
"""Decode the JSON file. Broken out for testing."""
try:
return json.load(handle)
except ValueError, e:
except ValueError as e:
LOG.exception(_("Could not decode scheduler options: '%s'") % e)
return {}