We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent b993751 commit 2b58903Copy full SHA for 2b58903
mamonsu/plugins/pgsql/driver/pool.py
@@ -127,9 +127,13 @@ def is_pgpro_ee(self, db=None):
127
return False
128
if db in self._cache['pgproee']:
129
return self._cache['pgproee'][db]
130
- self._cache['pgproee'][db] = (
131
- self.query('select pgpro_edition()')[0][0].lower() == 'enterprise'
132
- )
+ try:
+ ed = self.query('select pgpro_edition()')[0][0]
+ self._connections[db].log.info('pgpro_edition is {}'.format(ed))
133
+ self._cache['pgproee'][db] = (ed.lower() == 'enterprise')
134
+ except:
135
+ self._connections[db].log.info('pgpro_edition() is not defined')
136
+ self._cache['pgproee'][db] = False
137
138
139
def extension_installed(self, ext, db=None):
0 commit comments