From b12d27291609d79abe2e0e0817acdf5a1c3e2acb Mon Sep 17 00:00:00 2001 From: Colin Noga Date: Sun, 22 Jul 2012 21:26:40 -0500 Subject: pushed a fix to prevent outdated map errors from causing crashes --- src/mapfile.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'src') diff --git a/src/mapfile.py b/src/mapfile.py index a6ebede..e1494b1 100644 --- a/src/mapfile.py +++ b/src/mapfile.py @@ -79,7 +79,10 @@ def load(string): obj = clsObj() for attrName in clsObj.__dump_attribs__: - setattr(obj, attrName, source[attrName]) + try: + setattr(obj, attrName, source[attrName]) + except: + print "{0} was missing the attribute {1}".format(obj, attrName) if hasattr(obj, '_preload'): obj._preload(source) -- cgit v1.2.3