mirror of
https://github.com/aljazceru/turso.git
synced 2026-01-04 17:04:18 +01:00
sqlite3: Switch to tracing logger
...we now actually see logging from core too.
This commit is contained in:
@@ -2,7 +2,7 @@
|
||||
#![allow(non_camel_case_types)]
|
||||
|
||||
use limbo_core::Value;
|
||||
use log::trace;
|
||||
use tracing::trace;
|
||||
use std::ffi::{self, CStr, CString};
|
||||
|
||||
use std::rc::Rc;
|
||||
@@ -85,7 +85,7 @@ static INIT_DONE: std::sync::Once = std::sync::Once::new();
|
||||
#[no_mangle]
|
||||
pub unsafe extern "C" fn sqlite3_initialize() -> ffi::c_int {
|
||||
INIT_DONE.call_once(|| {
|
||||
env_logger::init();
|
||||
tracing_subscriber::fmt::init();
|
||||
});
|
||||
SQLITE_OK
|
||||
}
|
||||
@@ -131,7 +131,7 @@ pub unsafe extern "C" fn sqlite3_open(
|
||||
SQLITE_OK
|
||||
}
|
||||
Err(e) => {
|
||||
log::trace!("error opening database {}: {:?}", filename, e);
|
||||
trace!("error opening database {}: {:?}", filename, e);
|
||||
SQLITE_CANTOPEN
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user