summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xtools/mock-meta.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/tools/mock-meta.py b/tools/mock-meta.py
index f185dbf2..a5d14ab7 100755
--- a/tools/mock-meta.py
+++ b/tools/mock-meta.py
@@ -262,8 +262,8 @@ class MetaDataHandler(object):
except ValueError:
raise WebException(hclient.BAD_REQUEST,
"%s: not an integer" % mybe_key)
- except KeyError:
- raise WebException(hclient.BAD_REQUEST,
+ except IndexError:
+ raise WebException(hclient.NOT_FOUND,
"Unknown key id %r" % mybe_key)
# Extract the possible sub-params
result = traverse(nparams[1:], {