I've defined a column declaratively like so
my_column = Column(Unicode(30), index=True, unique=True)
If I pass in an integer instead of a string, it will actually return all records that start with the string representation of that integer
>>> [obj.code for obj in Session.query(Model).filter_by(my_column=123).all()]
[u'123ad', u'123lpb', u'123xd8', u'123za0']
I would expect no results as no column exactly matches the string representation of my number