Closed williamstein closed 7 months ago
NOTE: This doesn't necessarily cause any serious problems at runtime -- it just happened once or twice and could have a "destabilizing influence" and that's not it. So NOT a high priority to fix!
Interesting - this feels like there might be something funky happening with transpilation here. The sslConfigToPsqlEnv
function itself is just a simple utility function to transform SSL configuration from this data structure:
...to this one (for the purpose of running a psql
command):
I wonder if the data
variable name conflicts with something else in that file somehow:
It's also possible that CoffeeScript doesn't like export const
function types, which is how sslConfigToPsqlEnv
is defined.
At any rate, I've opened a small PR (in draft state - it's tested, but would appreciate another set of eyes before merge) that addresses both of those possibilities, but I'm not sure I could confidently speak to why the above stack trace is happening without seeing whether we can obtain more context about when it happens. It's also possible that this PR could force whatever is causing the error to throw on import instead of when _ensure_database_exists
is called, so that's probably a good thing to keep in mind.
I don't understand this, but @schrodingersket recently introduced sslConfigToPsqlEnv, so maybe he will?