Skip to content

Commit 65479bc

Browse files
authored
allow unsigned extensions (#120)
1 parent 1f94f19 commit 65479bc

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

src/config.rs

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -86,6 +86,12 @@ impl Config {
8686
Ok(self)
8787
}
8888

89+
/// Allow to load third-party duckdb extensions.
90+
pub fn allow_unsigned_extensions(mut self) -> Result<Config> {
91+
self.set("allow_unsigned_extensions", "true")?;
92+
Ok(self)
93+
}
94+
8995
/// The maximum memory of the system (e.g. 1GB)
9096
pub fn max_memory(mut self, memory: &str) -> Result<Config> {
9197
self.set("max_memory", memory)?;
@@ -172,6 +178,7 @@ mod test {
172178
.default_order(crate::DefaultOrder::Desc)?
173179
.enable_external_access(true)?
174180
.enable_object_cache(false)?
181+
.allow_unsigned_extensions()?
175182
.max_memory("2GB")?
176183
.threads(4)?;
177184
let db = Connection::open_in_memory_with_flags(config)?;

0 commit comments

Comments
 (0)