https://prefect.io logo
Title
a

Andrew Pruchinski

09/08/2022, 6:17 PM
Good Afternoon! I have a question regarding using a snowflake query with wildcard
%
and pandas.read_sql. There seems to be an issue during compilation during a prefect flow run where it's complaining about the wildcard. We can run the queries outside of a prefect run no problem. When executing in prefect, we are getting formatting errors. Errors listed in threads
1
TypeError: %o format: an integer is required, not dict
ValueError: unsupported format character 'v' (0x76) at index 485
These errors would indicate that somewhere along the line, something is reading
name ILIKE '% vs XXXXXXX'
as
%
(wildcard + space) is being read a formatting method. And the other error was happening with the query
AND id NOT ILIKE '%lounge%'
so
%l
is being read as %o
Thank you in advance!
j

Jeff Hale

09/08/2022, 11:08 PM
Thank you. Sounds like you found a bug. What version of Prefect are you using? Assuming it's the latest, are you able to open a big report issue at prefecthg/prefect on GirHub?
a

Andrew Pruchinski

09/09/2022, 12:04 AM
We are using prefect 1.2 in production. Should i still open the issue? Also, we have an open branch transitioning to prefect 2.0 and can test it out there ASAP.
👍 1
j

Jeff Hale

09/09/2022, 12:23 AM
I think it is worth opening in 1.0.
a

Andrew Pruchinski

09/09/2022, 3:10 PM
After further local testing, It seems to fail outside of prefect now too. Apologies for the false alarm here
:thank-you: 1
👍 1