File tree Expand file tree Collapse file tree 1 file changed +10
-3
lines changed
Expand file tree Collapse file tree 1 file changed +10
-3
lines changed Original file line number Diff line number Diff line change @@ -2,6 +2,7 @@ package duckdb_go_bindings
22
33import (
44 "os"
5+ "runtime"
56 "strings"
67 "testing"
78
@@ -28,9 +29,15 @@ func TestOpenSQLiteDB(t *testing.T) {
2829 t .Fail ()
2930 }
3031
31- extDir , err := os .MkdirTemp ("" , "duckdb-ext-*" )
32- require .NoError (t , err )
33- SetConfig (config , "extension_directory" , extDir )
32+ // Work around a DuckDB v1.5.0 regression where the default extension
33+ // directory is malformed on Windows (https://github.com/duckdb/duckdb/pull/21260).
34+ // Uses os.MkdirTemp instead of t.TempDir() to avoid Windows cleanup failures when DuckDB
35+ // still holds extension file handles.
36+ if runtime .GOOS == "windows" {
37+ extDir , err := os .MkdirTemp ("" , "duckdb-ext-*" )
38+ require .NoError (t , err )
39+ SetConfig (config , "extension_directory" , extDir )
40+ }
3441
3542 var db Database
3643 defer Close (& db )
You can’t perform that action at this time.
0 commit comments