Skip to content

Commit 14e432e

Browse files
Address spurious sqlite warnings about synchronous
1 parent 3b2b22c commit 14e432e

3 files changed

Lines changed: 10 additions & 5 deletions

File tree

NEWS.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,7 @@
1+
# BrainGnomes 0.8-2
2+
3+
* Update RSQLite connections to default to `synchronous=NULL` to prevent spurious warnings
4+
15
# BrainGnomes 0.8-1
26

37
Released 2026-03-05
@@ -10,6 +14,7 @@ Released 2026-03-05
1014
* Harden prefetch caching and validation checks so that later failures invalidate skip logic
1115
* Make prefetch state query-specific so that an exact snapshot of templateflow files is retained
1216
* Move prefetch state files out of `templateflow_home` and into hashed project log paths; legacy state files in `templateflow_home` are now migrated and removed to avoid poisoning TemplateFlow standard-space discovery.
17+
* Expand TemplateFlow default to desc=None for T1w to mirror some versions of fmriprep.
1318
* Harden check on flywheel location to accommodate missing fw command.
1419

1520
# BrainGnomes 0.8

R/job_tracking_functions.R

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,7 @@ submit_tracking_query = function(str, sqlite_db, param = NULL) {
6666

6767
# check if tracking table exists in sqlite_db; if not, create it
6868
table_exists <- tryCatch({
69-
con <- dbConnect(RSQLite::SQLite(), sqlite_db) # establish connection
69+
con <- dbConnect(RSQLite::SQLite(), sqlite_db, synchronous = NULL) # establish connection
7070
on.exit(try(dbDisconnect(con), silent = TRUE), add = TRUE)
7171
sqliteSetBusyHandler(con, 10 * 1000) # busy_timeout of 10 seconds
7272
dbExistsTable(con, "job_tracking")
@@ -99,7 +99,7 @@ submit_tracking_query = function(str, sqlite_db, param = NULL) {
9999

100100
ensure_tracking_db_schema <- function(sqlite_db) {
101101
con <- tryCatch({
102-
dbConnect(RSQLite::SQLite(), sqlite_db)
102+
dbConnect(RSQLite::SQLite(), sqlite_db, synchronous = NULL)
103103
}, error = function(e) {
104104
stop(format_tracking_db_error(sqlite_db, operation = "ensure_tracking_db_schema connect", err = e), call. = FALSE)
105105
})
@@ -479,7 +479,7 @@ get_tracked_job_status <- function(job_id = NULL, return_children = FALSE, retur
479479
}
480480

481481
con <- tryCatch({
482-
dbConnect(RSQLite::SQLite(), sqlite_db)
482+
dbConnect(RSQLite::SQLite(), sqlite_db, synchronous = NULL)
483483
}, error = function(e) {
484484
stop(format_tracking_db_error(sqlite_db, operation = "get_tracked_job_status connect", err = e), call. = FALSE)
485485
})

R/sqlite_functions.R

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -210,7 +210,7 @@ submit_sqlite_query <- function(str = NULL, sqlite_db = NULL, param = NULL,
210210
checkmate::assert_logical(return_result)
211211
if(is.null(str) | is.null(sqlite_db)) return(invisible(NULL))
212212

213-
con <- dbConnect(RSQLite::SQLite(), sqlite_db) # establish connection
213+
con <- dbConnect(RSQLite::SQLite(), sqlite_db, synchronous = NULL) # establish connection
214214
sqliteSetBusyHandler(con, busy_timeout * 1000) # busy_timeout arg in seconds * 1000 ms
215215

216216
if (isTRUE(return_result)) {
@@ -257,7 +257,7 @@ sqlite_table_exists <- function(sqlite_db, table_name) {
257257
}
258258

259259
# Connect to database
260-
con <- DBI::dbConnect(RSQLite::SQLite(), sqlite_db)
260+
con <- DBI::dbConnect(RSQLite::SQLite(), sqlite_db, synchronous = NULL)
261261
on.exit(DBI::dbDisconnect(con), add = TRUE)
262262

263263
# Check if table exists

0 commit comments

Comments
 (0)