Closed eitsupi closed 5 months ago
From eitsupi/r-glaredb#11
If a function having optional struct argument is created as shown below, it seems to cause an error if NULL is passed on the R side.
NULL
pub fn sql(query: &str, connection: Option<RGlareDbConnection>) -> savvy::Result<RGlareDbExecutionOutput> { if let Some(connection) = connection { connection.sql(query) } else { RGlareDbConnection::default_in_memory()?.sql(query) } }
> sql("select 'hello'", NULL) Error: Expected RGlareDbConnection, got NULL
Oh, thanks for catching!
Should be fixed now. Please update the dev version of savvy-cli and run savvy-cli update.
savvy-cli
savvy-cli update
Wow, what a very quick update! Thanks.
From eitsupi/r-glaredb#11
If a function having optional struct argument is created as shown below, it seems to cause an error if
NULL
is passed on the R side.