I'm not sure whether this is a bug or user error, but in the Rails console, I can't use any of the static methods from the timescale gem. E.g. Timescaledb::Extension.version and Timescaledb::Stats.new([MyModel.hypertable]).to_h. So I also can't execute Timescaledb::Extension.update!. It seems that Timescaledb::Connection.instance is not initialized.
my_application(prod)> Timescaledb::Extension.installed?
(my_application):7:in '<main>': connection to server on socket "/var/run/postgresql/.s.PGSQL.5432" failed: No such file or directory (PG::ConnectionBad)
Is the server running locally and accepting connections on that socket?
my_application(prod)> Timescaledb::Connection.instance.connected?
=> false
I can't find any code that would initialize the connection when used within a Rails app. Should my app have a custom initializer that does so?