Allow configuring libsqlite location
I would like to bundle my own sqlite library, and setting the env variable is not viable. Can I pass it to the Database constructor or another config function?
Is it viable if you import a module before sqlite3 module is referenced at all that just does Deno.env.set to set the custom sqlite library path? Currently we just load the shared library when the module is evaluated, but if it helps we can lazy load it upon creating first instance of Database class.
Yes but that would require my app to have full --allow-env. Certainly I can do that for now but it is not my long term preference.
Edit: ah, I didn’t realize the library downloads the sqlite3 library when the module is imported. I’m going to vendor the library and remove that. Thanks for consideration of my request.
Closing as the design of this library prevents another mechanism.
@mxcl It can be altered without affecting performance I believe, we can make a new, manual entry point which allows configuration and make the default one from mod.ts download and cache it locally. If you are still interested, I can work on that
Certainly would mean I don’t have to vendor and apply my mods every release! I can do the work, just didn’t think it was possible since the import mechanism seemed to be controlled by the deno runtime at module load.