Open szymek156 opened 2 years ago
It's an issue with the signature of Migrator::run()
which I actually ran into while implementing #2001. To work around it I added .run_direct()
which takes a mutable reference to a connection and doesn't use the Acquire
trait. It's #[doc(hidden)]
because I didn't want to commit to the naming and make it part of the stable API.
I am running into an issue I am not capable to resolve by myself.
I have example code, where I want to call migrations inside the warp endpoint, using
SqliteConnection
:Produces following error
Interestingly enough when using connection pool, code compiles:
Code to reproduce:
cargo run
in: https://github.com/szymek156/sqlx/tree/szymek156/migration_in_warp/examples/sqlite/migration_in_warpI am aware of "workaround" stated here, but I don't know how to apply it in my case, nor it's even applicable.