Let me first show the output for one of your examples.
$ sqlitis "SELECT id FROM foo WHERE id = 128"
select([foo.c.id]).where(text('id') == 128)
That looks good to me, so what is the issue with this?
$ sqlitis "SELECT ckey, cval FROM tinfo WHERE ckey = version"
select([tinfo.c.ckey, tinfo.c.cval]).where(text('ckey'))
There seems to be no comparison.