Skip to content

Bump sqlx-core and sqlx-macros-core from 0.8.3 #35

@kanarus

Description

@kanarus
  • As of submitting this, the latest version of sqlx is 0.8.5, but the internal packages has breaking changes
    • This itself is expected, documented here
  • When tried to update:
error[E0050]: method `begin` has 1 parameter but the declaration in trait `sqlx_core::transaction::TransactionManager::begin` has 2
 --> /home/kanarus/projects/ohkami-rs/sqlx-d1/sqlx-d1-core/src/transaction.rs:8:15
  |
8 |         conn: &mut <Self::Database as sqlx_core::database::Database>::Connection,
  |               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ expected 2 parameters, found 1
  |
  = note: `begin` from trait: `fn(&'conn mut <<Self as TransactionManager>::Database as sqlx_core::database::Database>::Connection, Option<Cow<'static, str>>) -> Pin<Box<(dyn futures_core::Future<Output = Result<(), sqlx_core::Error>> + std::marker::Send + 'conn)>>`

error[E0046]: not all trait items implemented, missing: `get_transaction_depth`
 --> /home/kanarus/projects/ohkami-rs/sqlx-d1/sqlx-d1-core/src/transaction.rs:3:1
  |
3 | impl sqlx_core::transaction::TransactionManager for D1TransactionManager {
  | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ missing `get_transaction_depth` in implementation
  |
  = help: implement the missing item: `fn get_transaction_depth(_: &<<Self as TransactionManager>::Database as sqlx_core::database::Database>::Connection) -> usize { todo!() }`

error[E0061]: this function takes 2 arguments but 1 argument was supplied
   --> /home/kanarus/projects/ohkami-rs/sqlx-d1/sqlx-d1-core/src/connection.rs:148:13
    |
148 |             sqlx_core::transaction::Transaction::begin(self)
    |             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^------ argument #2 of type `Option<Cow<'static, str>>` is missing
    |
note: associated function defined here
   --> /home/kanarus/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/sqlx-core-0.8.5/src/transaction.rs:99:12
    |
99  |     pub fn begin(
    |            ^^^^^
help: provide the argument
    |
148 |             sqlx_core::transaction::Transaction::begin(self, /* Option<Cow<'static, str>> */)
    |                                                            +++++++++++++++++++++++++++++++++

Some errors have detailed explanations: E0046, E0050, E0061.
For more information about an error, try `rustc --explain E0046`.
error: could not compile `sqlx-d1-core` (lib) due to 3 previous errors

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions