From 9b3c019edb9489af1c9adff2a5e18e16f1037787 Mon Sep 17 00:00:00 2001 From: oyving Date: Thu, 17 Mar 2005 23:49:12 +0000 Subject: [PATCH] Fixed so that the PVVDB.__format method actually _checks_ the fields for a correct datatype. --- lib/mdb/db.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/lib/mdb/db.py b/lib/mdb/db.py index c5622fd..d326710 100644 --- a/lib/mdb/db.py +++ b/lib/mdb/db.py @@ -65,6 +65,8 @@ class PVVDB: continue name, value = line.strip().split(":", 1) value = value.split("#", 1)[0].strip() + if not value in ['scalar', 'list']: + raise PVVDBError, "%s not legal .format datatype." % value fmt[name] = value return fmt