Commit acc0952f authored by Éric Araujo's avatar Éric Araujo

The error message should contain the key as given, not normalized.

Backout of 2e047702df7f.  Reported by Jeremy Kloth.
parent 618b7303
......@@ -229,8 +229,10 @@ class Metadata:
def __delitem__(self, name):
field_name = self._convert_name(name)
# we let a KeyError propagate
del self._fields[field_name]
try:
del self._fields[field_name]
except KeyError:
raise KeyError(name)
self._set_best_version()
def __contains__(self, name):
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment