We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
The add function returns a BoxDynError which means all functions that return a sqlx::Error type will manually need to map_err to the Encode error.
sqlx::Error
map_err
Encode
A small code snippet or a link to a Github repo or Gist, with instructions on reproducing the bug.
pub async fn store_data( connection: &mut PgConnection, content: MyData, ) -> Result<Metadata, sqlx::Error> { let mut arguments = PgArguments::default(); arguments .add(i64::from(content.id)) .map_err(sqlx::Error::Encode)?; // do query }
rustc --version
The text was updated successfully, but these errors were encountered:
Successfully merging a pull request may close this issue.
Bug Description
The add function returns a BoxDynError which means all functions that return a
sqlx::Error
type will manually need tomap_err
to theEncode
error.Minimal Reproduction
A small code snippet or a link to a Github repo or Gist, with instructions on reproducing the bug.
Info
rustc --version
: 1.79.0The text was updated successfully, but these errors were encountered: