summaryrefslogtreecommitdiffstats
path: root/bitbake/lib/bb
diff options
context:
space:
mode:
Diffstat (limited to 'bitbake/lib/bb')
-rw-r--r--bitbake/lib/bb/persist_data.py5
1 files changed, 5 insertions, 0 deletions
diff --git a/bitbake/lib/bb/persist_data.py b/bitbake/lib/bb/persist_data.py
index bf8fd77bf1..c9e80ba967 100644
--- a/bitbake/lib/bb/persist_data.py
+++ b/bitbake/lib/bb/persist_data.py
@@ -77,6 +77,11 @@ class SQLTable(collections.MutableMapping):
77 self._execute("DELETE from %s where key=?;" % self.table, [key]) 77 self._execute("DELETE from %s where key=?;" % self.table, [key])
78 78
79 def __setitem__(self, key, value): 79 def __setitem__(self, key, value):
80 if not isinstance(key, basestring):
81 raise TypeError('Only string keys are supported')
82 elif not isinstance(value, basestring):
83 raise TypeError('Only string values are supported')
84
80 data = self._execute("SELECT * from %s where key=?;" % 85 data = self._execute("SELECT * from %s where key=?;" %
81 self.table, [key]) 86 self.table, [key])
82 exists = len(list(data)) 87 exists = len(list(data))