mirror of
https://github.com/launchbadge/sqlx.git
synced 2025-10-15 05:34:54 +00:00
fix: remove sqlformat
(#3545)
* removed sqlformat from sql-core/src/logger.rs causing ref error to FormatOptions * removed sqlformat from sql-core/src/logger.rs causing ref error to FormatOptions --------- Co-authored-by: tbarnes <tbarnes@tbserver.tbarnes-server.local>
This commit is contained in:
parent
19f40d87a6
commit
cadf152e99
19
Cargo.lock
generated
19
Cargo.lock
generated
@ -1995,6 +1995,7 @@ version = "0.30.1"
|
|||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||||
checksum = "2e99fb7a497b1e3339bc746195567ed8d3e24945ecd636e3619d20b9de9e9149"
|
checksum = "2e99fb7a497b1e3339bc746195567ed8d3e24945ecd636e3619d20b9de9e9149"
|
||||||
dependencies = [
|
dependencies = [
|
||||||
|
"bindgen",
|
||||||
"cc",
|
"cc",
|
||||||
"pkg-config",
|
"pkg-config",
|
||||||
"vcpkg",
|
"vcpkg",
|
||||||
@ -3306,17 +3307,6 @@ dependencies = [
|
|||||||
"der",
|
"der",
|
||||||
]
|
]
|
||||||
|
|
||||||
[[package]]
|
|
||||||
name = "sqlformat"
|
|
||||||
version = "0.2.3"
|
|
||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
||||||
checksum = "ce81b7bd7c4493975347ef60d8c7e8b742d4694f4c49f93e0a12ea263938176c"
|
|
||||||
dependencies = [
|
|
||||||
"itertools 0.12.1",
|
|
||||||
"nom",
|
|
||||||
"unicode_categories",
|
|
||||||
]
|
|
||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "sqlx"
|
name = "sqlx"
|
||||||
version = "0.8.2"
|
version = "0.8.2"
|
||||||
@ -3409,7 +3399,6 @@ dependencies = [
|
|||||||
"serde_json",
|
"serde_json",
|
||||||
"sha2",
|
"sha2",
|
||||||
"smallvec",
|
"smallvec",
|
||||||
"sqlformat",
|
|
||||||
"sqlx",
|
"sqlx",
|
||||||
"thiserror",
|
"thiserror",
|
||||||
"time",
|
"time",
|
||||||
@ -4140,12 +4129,6 @@ version = "0.1.13"
|
|||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||||
checksum = "0336d538f7abc86d282a4189614dfaa90810dfc2c6f6427eaf88e16311dd225d"
|
checksum = "0336d538f7abc86d282a4189614dfaa90810dfc2c6f6427eaf88e16311dd225d"
|
||||||
|
|
||||||
[[package]]
|
|
||||||
name = "unicode_categories"
|
|
||||||
version = "0.1.1"
|
|
||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
||||||
checksum = "39ec24b3121d976906ece63c9daad25b85969647682eee313cb5779fdd69e14e"
|
|
||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "untrusted"
|
name = "untrusted"
|
||||||
version = "0.9.0"
|
version = "0.9.0"
|
||||||
|
@ -69,7 +69,7 @@ regex = { version = "1.5.5", optional = true }
|
|||||||
serde = { version = "1.0.132", features = ["derive", "rc"], optional = true }
|
serde = { version = "1.0.132", features = ["derive", "rc"], optional = true }
|
||||||
serde_json = { version = "1.0.73", features = ["raw_value"], optional = true }
|
serde_json = { version = "1.0.73", features = ["raw_value"], optional = true }
|
||||||
sha2 = { version = "0.10.0", default-features = false, optional = true }
|
sha2 = { version = "0.10.0", default-features = false, optional = true }
|
||||||
sqlformat = "0.2.0"
|
#sqlformat = "0.2.0"
|
||||||
thiserror = "1.0.30"
|
thiserror = "1.0.30"
|
||||||
tokio-stream = { version = "0.1.8", features = ["fs"], optional = true }
|
tokio-stream = { version = "0.1.8", features = ["fs"], optional = true }
|
||||||
tracing = { version = "0.1.37", features = ["log"] }
|
tracing = { version = "0.1.37", features = ["log"] }
|
||||||
|
@ -60,8 +60,6 @@ pub(crate) fn private_level_filter_to_trace_level(
|
|||||||
private_level_filter_to_levels(filter).map(|(level, _)| level)
|
private_level_filter_to_levels(filter).map(|(level, _)| level)
|
||||||
}
|
}
|
||||||
|
|
||||||
pub use sqlformat;
|
|
||||||
|
|
||||||
pub struct QueryLogger<'q> {
|
pub struct QueryLogger<'q> {
|
||||||
sql: &'q str,
|
sql: &'q str,
|
||||||
rows_returned: u64,
|
rows_returned: u64,
|
||||||
@ -112,11 +110,12 @@ impl<'q> QueryLogger<'q> {
|
|||||||
summary.push_str(" …");
|
summary.push_str(" …");
|
||||||
format!(
|
format!(
|
||||||
"\n\n{}\n",
|
"\n\n{}\n",
|
||||||
|
self.sql /*
|
||||||
sqlformat::format(
|
sqlformat::format(
|
||||||
self.sql,
|
self.sql,
|
||||||
&sqlformat::QueryParams::None,
|
&sqlformat::QueryParams::None,
|
||||||
sqlformat::FormatOptions::default()
|
sqlformat::FormatOptions::default()
|
||||||
)
|
)*/
|
||||||
)
|
)
|
||||||
} else {
|
} else {
|
||||||
String::new()
|
String::new()
|
||||||
|
@ -416,11 +416,13 @@ impl<'q, R: Debug, S: Debug + DebugDiff, P: Debug> QueryPlanLogger<'q, R, S, P>
|
|||||||
summary.push_str(" …");
|
summary.push_str(" …");
|
||||||
format!(
|
format!(
|
||||||
"\n\n{}\n",
|
"\n\n{}\n",
|
||||||
|
self.sql /*
|
||||||
sqlformat::format(
|
sqlformat::format(
|
||||||
self.sql,
|
self.sql,
|
||||||
&sqlformat::QueryParams::None,
|
&sqlformat::QueryParams::None,
|
||||||
sqlformat::FormatOptions::default()
|
sqlformat::FormatOptions::default()
|
||||||
)
|
)
|
||||||
|
*/
|
||||||
)
|
)
|
||||||
} else {
|
} else {
|
||||||
String::new()
|
String::new()
|
||||||
|
@ -128,7 +128,7 @@ pub fn dupe_value<T>(_t: &T) -> T {
|
|||||||
|
|
||||||
#[test]
|
#[test]
|
||||||
fn test_dupe_value() {
|
fn test_dupe_value() {
|
||||||
let ref val = (String::new(),);
|
let val = &(String::new(),);
|
||||||
|
|
||||||
if false {
|
if false {
|
||||||
let _: i32 = dupe_value(&0i32);
|
let _: i32 = dupe_value(&0i32);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user