We’ve had production issues because of:
|
formatMany :: (ToRow q) => Connection -> Query -> [q] -> IO ByteString |
|
formatMany _ q [] = fmtError "no rows supplied" q [] |
|
formatMany conn q@(Query template) qs = do |
I think the function signature should be changed to:
formatMany :: (ToRow q) => Connection -> Query -> NonEmpty q -> IO ByteString
The breaking change is pretty much worth it, because anybody using this function that does not put a check (trivial to get wrong) will have a sleeping bug that blows up at the worst times.
We’ve had production issues because of:
postgresql-simple/src/Database/PostgreSQL/Simple.hs
Lines 174 to 176 in 6836ea6
I think the function signature should be changed to:
The breaking change is pretty much worth it, because anybody using this function that does not put a check (trivial to get wrong) will have a sleeping bug that blows up at the worst times.