powa-team / powa-web

PoWA user interface
http://powa.readthedocs.io/
73 stars 31 forks source link

powa-web not connecting to DB #75

Closed kel00s closed 5 years ago

kel00s commented 5 years ago

Hi,

I'm trying to use powa-web but getting below error in logs. I'm using docker image dalibo/powa-web

E 190404 11:29:52 web:1670] Uncaught exception POST /login/?next=%2F (172.17.0.1)
    HTTPServerRequest(protocol='http', host='localhost:18083', method='POST', uri='/login/?next=%2F', version='HTTP/1.1', remote_ip='172.17.0.1')
    Traceback (most recent call last):
      File "/usr/local/lib/python2.7/dist-packages/tornado/web.py", line 1590, in _execute
        result = method(*self.path_args, **self.path_kwargs)
      File "/usr/local/lib/python2.7/dist-packages/powa/user.py", line 32, in post
        if version[0:2] != __VERSION_NUM__[0:2]:
    TypeError: 'NoneType' object has no attribute '__getitem__'

Looks like I've installed all necessary extensions on db:

(postgres@[local]:5432) [postgres] > \dx
                                     List of installed extensions
        Name        │ Version │   Schema   │                        Description
────────────────────┼─────────┼────────────┼───────────────────────────────────────────────────────────
 btree_gist         │ 1.2     │ public     │ support for indexing common datatypes in GiST
 hypopg             │ 1.1.2   │ public     │ Hypothetical indexes for PostgreSQL
 pg_qualstats       │ 1.0.7   │ public     │ An extension collecting statistics about quals
 pg_stat_kcache     │ 2.1.1   │ public     │ Kernel statistics gathering
 pg_stat_statements │ 1.4     │ public     │ track execution statistics of all SQL statements executed
 plpgsql            │ 1.0     │ pg_catalog │ PL/pgSQL procedural language
 powa               │ 3.2.0   │ public     │ PostgreSQL Workload Analyser-core
(7 rows)
rjuju commented 5 years ago

Hi,

That's weird. I see that you installed all the extension in the postgres database, did you configure powa-web to connect to postgres and not powa?

kel00s commented 5 years ago

I've added extensions not to the right DB. Thank you! Closing