Closed
Description
Description
Hello guys, im not able to compile minimal example (below) with rusqlite backend, where im getting follow error:
error[E0277]: the trait bound `ValueRef<'_>: From<&bool>` is not satisfied
--> src/main.rs:4:1
|
4 | sea_query::sea_query_driver_rusqlite!();
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ the trait `From<&bool>` is not implemented for `ValueRef<'_>`
|
= help: the following implementations were found:
<ValueRef<'a> as From<&'a [u8]>>
<ValueRef<'a> as From<&'a rusqlite::types::Value>>
<ValueRef<'a> as From<&'a str>>
<ValueRef<'a> as From<Option<T>>>
= note: required because of the requirements on the impl of `Into<ValueRef<'_>>` for `&bool`
= note: required because of the requirements on the impl of `From<&bool>` for `ToSqlOutput<'_>`
note: required by `from`
= note: this error originates in the macro `opt_string_to_sql` (in Nightly builds, run with -Z macro-backtrace for more info)
Steps to Reproduce
- run
cargo init --bin
- modify Cargo.toml
[package]
name = "sea_query_test"
version = "0.1.0"
edition = "2021"
[dependencies]
sea-query = { version = "^0", features = [
"rusqlite"
]}
[dependencies.rusqlite]
version = "^0.27"
features = [
"bundled"
]
- modify main.rs
use rusqlite::{Connection, Result};
use sea_query::*;
sea_query::sea_query_driver_rusqlite!();
use sea_query_driver_rusqlite::RusqliteValues;
fn main() -> Result<()> {
println!("test");
Ok(())
}
- run
cargo update && cargo build
Versions
Linux: Linux user-server 5.4.0-99-generic #112-Ubuntu SMP Thu Feb 3 13:50:55 UTC 2022 x86_64 x86_64 x86_64 GNU/Linux
rustc: 1.57.0
cargo: 1.57.0
Additional Information
cargo tree | grep sea-
└── sea-query v0.23.0
└── sea-query-derive v0.2.0 (proc-macro)
cargo tree
sea_query_test v0.1.0 (/home/user/Temp/sea_query_test)
├── rusqlite v0.27.0
│ ├── bitflags v1.3.2
│ ├── fallible-iterator v0.2.0
│ ├── fallible-streaming-iterator v0.1.9
│ ├── hashlink v0.7.0
│ │ └── hashbrown v0.11.2
│ │ └── ahash v0.7.6
│ │ ├── getrandom v0.2.5
│ │ │ ├── cfg-if v1.0.0
│ │ │ └── libc v0.2.121
│ │ └── once_cell v1.10.0
│ │ [build-dependencies]
│ │ └── version_check v0.9.4
│ ├── libsqlite3-sys v0.24.1
│ │ [build-dependencies]
│ │ ├── cc v1.0.73
│ │ ├── pkg-config v0.3.24
│ │ └── vcpkg v0.2.15
│ ├── memchr v2.4.1
│ └── smallvec v1.8.0
└── sea-query v0.23.0
└── sea-query-derive v0.2.0 (proc-macro)
├── heck v0.3.3
│ └── unicode-segmentation v1.9.0
├── proc-macro2 v1.0.36
│ └── unicode-xid v0.2.2
├── quote v1.0.17
│ └── proc-macro2 v1.0.36 (*)
├── syn v1.0.89
│ ├── proc-macro2 v1.0.36 (*)
│ ├── quote v1.0.17 (*)
│ └── unicode-xid v0.2.2
└── thiserror v1.0.30
└── thiserror-impl v1.0.30 (proc-macro)
├── proc-macro2 v1.0.36 (*)
├── quote v1.0.17 (*)
└── syn v1.0.89 (*)
Metadata
Metadata
Assignees
Labels
No labels