Files
kvspool/bindings/kvpy/tests/read_all.py
Troy D. Hanson 4456e62bda wip
2016-06-26 10:44:59 -04:00

17 lines
369 B
Python
Executable File

#!/usr/bin/python
# so we don't have to install kvpy.so (or we could
# have set PYTHONPATH to include its dir beforehand)
import sys
sys.path.append("../build/lib.linux-i686-2.6")
import kvspool
kv = kvspool.Kvspool("spool")
kv.blocking = 0
while True:
d = kv.read()
if (d == None):
break
for key in d.keys():
print "key: " + key + " value: " + d[key]