◐ Shell
clean mode source ↗

Message 72725 - Python tracker

sq_dict review:

have sqlite quote/escape self._mtn before using it with a python %s
substitution.  or pass it into the sql query function as a positional ?
parameter like you do for keys and values.  (avoid sql injection)

raise a TypeError rather than a ValueError when you don't like the key
or value type.

also, to test the type, isinstance(val, str) is better than using type(val).