Hi. I saw an issue with the same output, but all documentation links given there do not exist anymore
https://github.com/apache/incubator-superset/issues/316
Im installing superset in an Amazon EC2 instance. I can't find the superset version too.
Open superset main page
sqlalchemy.exc.OperationalError
sqlalchemy.exc.OperationalError: (sqlite3.OperationalError) no such table: user_attribute
[SQL: SELECT user_attribute.welcome_dashboard_id AS user_attribute_welcome_dashboard_id
FROM user_attribute
WHERE user_attribute.user_id = ?]
[parameters: ('1',)]
(Background on this error at: http://sqlalche.me/e/e3q8
Traceback (most recent call last):
File "/home/ubuntu/git/superset/venv/lib/python3.6/site-packages/sqlalchemy/engine/base.py", line 1244, in _execute_context
cursor, statement, parameters, context
File "/home/ubuntu/git/superset/venv/lib/python3.6/site-packages/sqlalchemy/engine/default.py", line 552, in do_execute
cursor.execute(statement, parameters)
sqlite3.OperationalError: no such table: user_attribute
The above exception was the direct cause of the following exception:
Traceback (most recent call last):
File "/home/ubuntu/git/superset/venv/lib/python3.6/site-packages/flask/app.py", line 1997, in __call__
return self.wsgi_app(environ, start_response)
File "/home/ubuntu/git/superset/venv/lib/python3.6/site-packages/flask/app.py", line 1985, in wsgi_app
response = self.handle_exception(e)
File "/home/ubuntu/git/superset/venv/lib/python3.6/site-packages/flask/app.py", line 1540, in handle_exception
reraise(exc_type, exc_value, tb)
File "/home/ubuntu/git/superset/venv/lib/python3.6/site-packages/flask/_compat.py", line 33, in reraise
raise value
File "/home/ubuntu/git/superset/venv/lib/python3.6/site-packages/flask/app.py", line 1982, in wsgi_app
response = self.full_dispatch_request()
File "/home/ubuntu/git/superset/venv/lib/python3.6/site-packages/flask/app.py", line 1614, in full_dispatch_request
rv = self.handle_user_exception(e)
File "/home/ubuntu/git/superset/venv/lib/python3.6/site-packages/flask/app.py", line 1517, in handle_user_exception
reraise(exc_type, exc_value, tb)
File "/home/ubuntu/git/superset/venv/lib/python3.6/site-packages/flask/_compat.py", line 33, in reraise
raise value
File "/home/ubuntu/git/superset/venv/lib/python3.6/site-packages/flask/app.py", line 1612, in full_dispatch_request
rv = self.dispatch_request()
File "/home/ubuntu/git/superset/venv/lib/python3.6/site-packages/flask/app.py", line 1598, in dispatch_request
return self.view_functionsrule.endpoint
File "/home/ubuntu/git/superset/venv/lib/python3.6/site-packages/superset/views/core.py", line 2768, in welcome
.filter_by(user_id=g.user.get_id())
File "/home/ubuntu/git/superset/venv/lib/python3.6/site-packages/sqlalchemy/orm/query.py", line 3305, in scalar
ret = self.one()
File "/home/ubuntu/git/superset/venv/lib/python3.6/site-packages/sqlalchemy/orm/query.py", line 3275, in one
ret = self.one_or_none()
File "/home/ubuntu/git/superset/venv/lib/python3.6/site-packages/sqlalchemy/orm/query.py", line 3244, in one_or_none
ret = list(self)
File "/home/ubuntu/git/superset/venv/lib/python3.6/site-packages/sqlalchemy/orm/query.py", line 3317, in __iter__
return self._execute_and_instances(context)
File "/home/ubuntu/git/superset/venv/lib/python3.6/site-packages/sqlalchemy/orm/query.py", line 3342, in _execute_and_instances
result = conn.execute(querycontext.statement, self._params)
File "/home/ubuntu/git/superset/venv/lib/python3.6/site-packages/sqlalchemy/engine/base.py", line 988, in execute
return meth(self, multiparams, params)
File "/home/ubuntu/git/superset/venv/lib/python3.6/site-packages/sqlalchemy/sql/elements.py", line 287, in _execute_on_connection
return connection._execute_clauseelement(self, multiparams, params)
File "/home/ubuntu/git/superset/venv/lib/python3.6/site-packages/sqlalchemy/engine/base.py", line 1107, in _execute_clauseelement
distilled_params,
File "/home/ubuntu/git/superset/venv/lib/python3.6/site-packages/sqlalchemy/engine/base.py", line 1248, in _execute_context
e, statement, parameters, cursor, context
File "/home/ubuntu/git/superset/venv/lib/python3.6/site-packages/sqlalchemy/engine/base.py", line 1466, in _handle_dbapi_exception
util.raise_from_cause(sqlalchemy_exception, exc_info)
File "/home/ubuntu/git/superset/venv/lib/python3.6/site-packages/sqlalchemy/util/compat.py", line 383, in raise_from_cause
reraise(type(exception), exception, tb=exc_tb, cause=cause)
File "/home/ubuntu/git/superset/venv/lib/python3.6/site-packages/sqlalchemy/util/compat.py", line 128, in reraise
raise value.with_traceback(tb)
File "/home/ubuntu/git/superset/venv/lib/python3.6/site-packages/sqlalchemy/engine/base.py", line 1244, in _execute_context
cursor, statement, parameters, context
File "/home/ubuntu/git/superset/venv/lib/python3.6/site-packages/sqlalchemy/engine/default.py", line 552, in do_execute
cursor.execute(statement, parameters)
sqlalchemy.exc.OperationalError: (sqlite3.OperationalError) no such table: user_attribute
[SQL: SELECT user_attribute.welcome_dashboard_id AS user_attribute_welcome_dashboard_id
FROM user_attribute
WHERE user_attribute.user_id = ?]
[parameters: ('1',)]
(Background on this error at: http://sqlalche.me/e/e3q8)
=> install superset as the guide indicates
=> run this in the superset dir:
. venv/bin/activate
superset runserver -p 8080 -d
=> access superset from the browser
Anyone looking into this?... I am experiencing the exact error whenever I try to run my superset instance.
i am following this guide: https://reflectivedata.com/getting-started-apache-superset-enterprise-ready-business-intelligence-platform/
and the same is happening.
I am running this on Ubuntu 18.04.1 LTS with python 3.6.7 and the following packages:
Package Version
alembic 1.0.8
amqp 2.4.2
asn1crypto 0.24.0
Babel 2.6.0
billiard 3.5.0.5
bleach 3.1.0
boto3 1.4.7
botocore 1.7.48
cchardet 2.1.4
celery 4.2.2
certifi 2019.3.9
cffi 1.12.2
chardet 3.0.4
click 6.7
colorama 0.3.9
contextlib2 0.5.5
cryptography 2.6.1
defusedxml 0.5.0
docutils 0.14
et-xmlfile 1.0.1
Flask 0.12.4
Flask-AppBuilder 1.12.5
Flask-Babel 0.12.2
Flask-Caching 1.7.0
Flask-Compress 1.4.0
Flask-Login 0.4.1
Flask-Migrate 2.4.0
Flask-OpenID 1.2.5
Flask-SQLAlchemy 2.3.2
Flask-WTF 0.14.2
flower 0.9.3
future 0.16.0
geographiclib 1.49
geopy 1.19.0
gunicorn 19.9.0
humanize 0.5.1
idna 2.8
ijson 2.3
isodate 0.6.0
itsdangerous 1.1.0
jdcal 1.4
Jinja2 2.10
jmespath 0.9.4
jsonlines 1.2.0
jsonschema 2.6.0
kombu 4.3.0
linear-tsv 1.1.0
Mako 1.0.8
Markdown 3.1
MarkupSafe 1.1.1
numpy 1.16.2
openpyxl 2.4.11
pandas 0.23.4
parsedatetime 2.4
pathlib2 2.3.3
pip 19.0.3
pkg-resources 0.0.0
polyline 1.3.2
pycparser 2.19
pydruid 0.5.2
PyHive 0.6.1
PyJWT 1.7.1
python-dateutil 2.8.0
python-editor 1.0.4
python-geohash 0.8.5
python3-openid 3.1.0
pytz 2018.9
PyYAML 5.1
requests 2.21.0
rfc3986 1.2.0
s3transfer 0.1.13
sasl 0.2.1
setuptools 40.8.0
simplejson 3.16.0
six 1.12.0
SQLAlchemy 1.3.1
SQLAlchemy-Utils 0.33.11
sqlparse 0.3.0
superset 0.28.1
tableschema 1.3.3
tabulator 1.19.0
thrift 0.11.0
thrift-sasl 0.3.0
tornado 5.1.1
unicodecsv 0.14.1
Unidecode 1.0.23
urllib3 1.24.1
vine 1.3.0
webencodings 0.5.1
Werkzeug 0.15.1
WTForms 2.2.1
xlrd 1.2.0
Looks like you didn't run superset db upgrade
, are you sure you followed the instructions?
@wwivywwivy windows insn't supported.
Looks like you didn't run
superset db upgrade
, are you sure you followed the instructions?@wwivywwivy windows insn't supported.
ok, thank you~
Looks like you didn't run
superset db upgrade
, are you sure you followed the instructions? @mistercrunch
I did. But to no avail. still getting the same error.
Looks like you didn't run
superset db upgrade
, are you sure you followed the instructions?
@mistercrunch
I did too. Still getting the error
Are you sure db upgrade
didn't fail? The error message says that you're missing a table, this table should have been created during the db upgrade
@mistercrunch is there a work-around if db upgrade
fails even after several retries/attempts?
same error
@mistercrunch is there a work-around if
db upgrade
fails even after several retries/attempts?
I am also experiencing same issue, and yes, superset db upgrade
fails too, with revision cannot find error.
tried @XuanmoFeng 's suggestion, first did pip install sqlalchemy==1.2.18 then did db upgrade, works for me.
I got the same error. I tried following steps
pip install sqlalchemy==1.2.18
superset db upgrade
It worked like charm.
@midhunt your way worked well for me,thank you
@midhunt it works well for me too, nice
I got the same error. I tried following steps
pip install sqlalchemy==1.2.18
superset db upgrade
It worked like charm.
Tried this and still getting the error
2019-09-18 18:48:21,012:ERROR:flask_appbuilder.security.sqla.manager:DB Creation and initialization failed: (sqlite3.OperationalError) unable to open database file (Background on this error at: http://sqlalche.me/e/e3q8)
someone got any solutions ?
I got the same no such table: user_attribute
error after proceeding to the admin after running superset db upgrade
.
For me the problem wasn't about the incompatible sqlalchemy version but a missing SUPERSET_CONFIG_PATH
environment variable.
I did not got an error while running the superset db upgrade
command but only the response below:
2019-09-25 11:19:11,722:INFO:root:Configured event logger of type <class 'superset.utils.log.DBEventLogger'>
INFO [alembic.runtime.migration] Context impl SQLiteImpl.
INFO [alembic.runtime.migration] Will assume transactional DDL.
It took me quite some time to notice the INFO message above that it was trying to insert the data to a SQLite database (which didn't ever exist nor was created by this command) instead of my PostgreSQL database which remained empty. I would expect an error message to be presented in such case.
My Superset config file was in the project root where i run the commands. I was able to successfully run superset init
and superset run
commands even though the environment variable was not set. As such, I thought superset commands were able to run as long as there is the config file present. However it seems that this is not the case for superset db upgrade
command.
I'm running the 0.34.0 version of Superset.
Great, this was also my problem. Had to do the followings:
export SUPERSET_CONFIG_PATH=/home/user/superset_config.py
superset db upgrade
superset init
And then all worked
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. For admin, please label this issue .pinned
to prevent stale bot from closing the issue.
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. For admin, please label this issue .pinned
to prevent stale bot from closing the issue.
Most helpful comment
I got the same
no such table: user_attribute
error after proceeding to the admin after runningsuperset db upgrade
.For me the problem wasn't about the incompatible sqlalchemy version but a missing
SUPERSET_CONFIG_PATH
environment variable.I did not got an error while running the
superset db upgrade
command but only the response below:It took me quite some time to notice the INFO message above that it was trying to insert the data to a SQLite database (which didn't ever exist nor was created by this command) instead of my PostgreSQL database which remained empty. I would expect an error message to be presented in such case.
My Superset config file was in the project root where i run the commands. I was able to successfully run
superset init
andsuperset run
commands even though the environment variable was not set. As such, I thought superset commands were able to run as long as there is the config file present. However it seems that this is not the case forsuperset db upgrade
command.I'm running the 0.34.0 version of Superset.