mcfunley / pugsql

A HugSQL-inspired database library for Python
https://pugsql.org
Apache License 2.0
673 stars 22 forks source link

Infinite recursive loop in _visit_bindparam when using sqlalchemy has_table #30

Open stevosaurus opened 4 years ago

stevosaurus commented 4 years ago

After importing pugsql, calling sqlalchemy's has_table method causes an infinite recursive loop. This may happen when any BindParameter is used but I am not sure.

To reproduce: -Import pugsql -Create an MSSQL pyodbc sqlalchemy engine -Call the dialects has_table method like this:

engine.dialect.has_table(engine, table, schema=schema)

mcfunley commented 3 years ago

Does this happen if you just call create_engine with your parameters to connect (i.e. if you aren't using pugsql)? A naive test case doesn't reproduce it.