Skip to content

Commit

Permalink
chore(deps): bump diesel_migrations from 2.0.0 to 2.1.0 (#3455)
Browse files Browse the repository at this point in the history
* chore(deps): bump diesel_migrations from 2.0.0 to 2.1.0

Bumps diesel_migrations from 2.0.0 to 2.1.0.

---
updated-dependencies:
- dependency-name: diesel_migrations
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <[email protected]>

* Be explicit on the `FromSql` impl used

There are now two implementations of `FromSql` for `Vec<u8>`. Updated
the `FromSql` usage to be explicit on which one to utilize.

```
    = note: multiple `impl`s satisfying `Vec<u8>: diesel::deserialize::FromSql<_, Pg>` found in the `diesel` crate:
           - impl<ST, DB> diesel::deserialize::FromSql<ST, DB> for Vec<u8>
             where DB: Backend, *const [u8]: diesel::deserialize::FromSql<ST, DB>;
           - impl<T, ST> diesel::deserialize::FromSql<Array<ST>, Pg> for Vec<T>
             where T: diesel::deserialize::FromSql<ST, Pg>;
```

---------

Signed-off-by: dependabot[bot] <[email protected]>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Nick Santana <[email protected]>
  • Loading branch information
dependabot[bot] and nick-mobilecoin authored Jul 26, 2023
1 parent 3667348 commit f5b5871
Show file tree
Hide file tree
Showing 3 changed files with 25 additions and 16 deletions.
37 changes: 23 additions & 14 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion fog/sql_recovery_db/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ chrono = "0.4"
clap = { version = "4.1", features = ["derive", "env"] }
diesel = { version = "2.0.3", features = ["chrono", "postgres", "r2d2"] }
diesel-derive-enum = { version = "2.1.0", features = ["postgres"] }
diesel_migrations = { version = "2.0.0", features = ["postgres"] }
diesel_migrations = { version = "2.1.0", features = ["postgres"] }
displaydoc = { version = "0.2", default-features = false }
prost = "0.11"
r2d2 = "0.8.10"
Expand Down
2 changes: 1 addition & 1 deletion fog/sql_recovery_db/src/sql_types.rs
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ impl fmt::Display for SqlCompressedRistrettoPublic {

impl FromSql<diesel::sql_types::Binary, Pg> for SqlCompressedRistrettoPublic {
fn from_sql(value: PgValue) -> deserialize::Result<Self> {
let vec = <Vec<u8>>::from_sql(value)?;
let vec = <Vec<u8> as FromSql<diesel::sql_types::Binary, Pg>>::from_sql(value)?;
if vec.len() != 32 {
return Err("SqlCompressedRistrettoPublic: Invalid array
length"
Expand Down

0 comments on commit f5b5871

Please sign in to comment.