alexvaut opened a new issue, #23468:
URL: https://github.com/apache/superset/issues/23468
#### How to reproduce the bug
- Install superset helm chart superset-0.8.4 (version 1.X of superset by
default)
- Upgrade to superset helm chart superset-0.8.8 (version 2.X of superset
**by default**)
```
helm upgrade --install --values superset-values.yaml superset
superset/superset --wait
```
### Expected results
Upgrade and DB migration sre working fine and the application is usable.
### Actual results
The application is not usable, all dashboards are broken. This is the error
I get in the worker:
```
File "/usr/local/lib/python3.8/site-packages/sqlalchemy/util/compat.py",
line 182, in raise_
raise exception
File "/usr/local/lib/python3.8/site-packages/sqlalchemy/engine/base.py",
line 1276, in _execute_context
self.dialect.do_execute(
File
"/usr/local/lib/python3.8/site-packages/sqlalchemy/engine/default.py", line
608, in do_execute
cursor.execute(statement, parameters)
sqlalchemy.exc.ProgrammingError: (psycopg2.errors.UndefinedColumn) column
dbs.allow_multi_schema_metadata_fetch does not exist
LINE 1: ..., dbs.force_ctas_schema AS dbs_force_ctas_schema, dbs.allow_...
^
[SQL: SELECT dbs.uuid AS dbs_uuid, dbs.created_on AS dbs_created_on,
dbs.changed_on AS dbs_changed_on, dbs.id AS dbs_id, dbs.verbose_name AS
dbs_verbose_name, dbs.database_name AS dbs_database_name, dbs.sqlalchemy_uri AS
dbs_sqlalchemy_uri, dbs.password AS dbs_password, dbs.cache_timeout AS
dbs_cache_timeout, dbs.select_as_create_table_as AS
dbs_select_as_create_table_as, dbs.expose_in_sqllab AS dbs_expose_in_sqllab,
dbs.configuration_method AS dbs_configuration_method, dbs.allow_run_async AS
dbs_allow_run_async, dbs.allow_file_upload AS dbs_allow_file_upload,
dbs.allow_ctas AS dbs_allow_ctas, dbs.allow_cvas AS dbs_allow_cvas,
dbs.allow_dml AS dbs_allow_dml, dbs.force_ctas_schema AS dbs_force_ctas_schema,
dbs.allow_multi_schema_metadata_fetch AS dbs_allow_multi_schema_metadata_fetch,
dbs.extra AS dbs_extra, dbs.encrypted_extra AS dbs_encrypted_extra,
dbs.impersonate_user AS dbs_impersonate_user, dbs.server_cert AS
dbs_server_cert, dbs.is_managed_externally AS dbs_is_managed_extern
ally, dbs.external_url AS dbs_external_url, dbs.created_by_fk AS
dbs_created_by_fk, dbs.changed_by_fk AS dbs_changed_by_fk
FROM dbs
WHERE dbs.id = %(param_1)s]
[parameters: {'param_1': 1}]
(Background on this error at: http://sqlalche.me/e/13/f405)
```
#### Screenshots
Several 500 error code here and there.
### Environment
- EKS/Kubernetes
- browser type and version: 'Edge 111.0.1661.44'
- superset version: `2.0.1`
- python version: `3.8.12`
- helm chart version: `0.8.8`
- node.js version: `not found`
- I just set the superset password in values.yaml, nothig else.
- OIDC is setup with keycloak
- any feature flags active: `FEATURE_FLAGS = { "ENABLE_TEMPLATE_PROCESSING":
True, "EMBEDDED_SUPERSET": True, "ALLOW_FULL_CSV_EXPORT": True,
"DASHBOARD_CROSS_FILTERS": True, "DASHBOARD_FILTERS_EXPERIMENTAL": True }`
### Checklist
Make sure to follow these steps before submitting your issue - thank you!
- [x] I have checked the superset logs for python stacktraces and included
it here as text if there are any.
- [x] I have reproduced the issue with at least the latest released version
of superset.
- [x] I have checked the issue tracker for the same issue and I haven't
found one similar.
### Additional context
At first I thought it was the same as
https://github.com/apache/superset/issues/19100 but no the error is not the
same, in my case it's the `column dbs.allow_multi_schema_metadata_fetch does
not exist`. So I looked at the migration script adding it and simply run this
in postgreSQL:
`ALTER TABLE dbs ADD COLUMN allow_multi_schema_metadata_fetch boolean
DEFAULT true;`
So now at least the application is usable. But the superset-init-db pod
keeps restarting (it's on the same image `apache/superset:2.0.1`). There are no
errors at all, just few warnings:
```
Requirement already satisfied: psycopg2-binary==2.9.1 in
/usr/local/lib/python3.8/site-packages (2.9.1)
Requirement already satisfied: redis==3.5.3 in
/usr/local/lib/python3.8/site-packages (3.5.3)
Collecting flask-oidc==1.4.0
Downloading flask-oidc-1.4.0.tar.gz (30 kB)
Collecting itsdangerous==2.0.1
Downloading itsdangerous-2.0.1-py3-none-any.whl (18 kB)
Collecting Flask-OpenID==1.3.0
Downloading Flask_OpenID-1.3.0-py3-none-any.whl (9.3 kB)
Requirement already satisfied: Flask in
/usr/local/lib/python3.8/site-packages (from flask-oidc==1.4.0) (2.0.3)
Collecting oauth2client
Downloading oauth2client-4.1.3-py2.py3-none-any.whl (98 kB)
Requirement already satisfied: six in /usr/local/lib/python3.8/site-packages
(from flask-oidc==1.4.0) (1.16.0)
Collecting python3-openid>=2.0
Downloading python3_openid-3.2.0-py3-none-any.whl (133 kB)
Requirement already satisfied: Jinja2>=3.0 in
/usr/local/lib/python3.8/site-packages (from Flask->flask-oidc==1.4.0) (3.0.3)
Requirement already satisfied: click>=7.1.2 in
/usr/local/lib/python3.8/site-packages (from Flask->flask-oidc==1.4.0) (8.0.4)
Requirement already satisfied: Werkzeug>=2.0 in
/usr/local/lib/python3.8/site-packages (from Flask->flask-oidc==1.4.0) (2.0.3)
Requirement already satisfied: MarkupSafe>=2.0 in
/usr/local/lib/python3.8/site-packages (from
Jinja2>=3.0->Flask->flask-oidc==1.4.0) (2.0.1)
Collecting defusedxml
Downloading defusedxml-0.7.1-py2.py3-none-any.whl (25 kB)
Collecting rsa>=3.1.4
Downloading rsa-4.9-py3-none-any.whl (34 kB)
Collecting pyasn1-modules>=0.0.5
Downloading pyasn1_modules-0.2.8-py2.py3-none-any.whl (155 kB)
Collecting httplib2>=0.9.1
Downloading httplib2-0.22.0-py3-none-any.whl (96 kB)
Collecting pyasn1>=0.1.7
Downloading pyasn1-0.4.8-py2.py3-none-any.whl (77 kB)
Requirement already satisfied:
pyparsing!=3.0.0,!=3.0.1,!=3.0.2,!=3.0.3,<4,>=2.4.2 in
/usr/local/lib/python3.8/site-packages (from
httplib2>=0.9.1->oauth2client->flask-oidc==1.4.0) (3.0.6)
Building wheels for collected packages: flask-oidc
Building wheel for flask-oidc (setup.py): started
Building wheel for flask-oidc (setup.py): finished with status 'done'
Created wheel for flask-oidc:
filename=flask_oidc-1.4.0-py2.py3-none-any.whl size=17528
sha256=77c26729c52f7fce863151210570d03c856f727266bd4f410f20cb5815faa235
Stored in directory:
/root/.cache/pip/wheels/c4/43/01/872857ed98e5030fbb5ea60f3e61d5ff0c6afdccb1ad8e0526
Successfully built flask-oidc
Installing collected packages: pyasn1, rsa, pyasn1-modules, itsdangerous,
httplib2, defusedxml, python3-openid, oauth2client, Flask-OpenID, flask-oidc
Attempting uninstall: itsdangerous
Found existing installation: itsdangerous 2.1.1
Uninstalling itsdangerous-2.1.1:
Successfully uninstalled itsdangerous-2.1.1
Successfully installed Flask-OpenID-1.3.0 defusedxml-0.7.1 flask-oidc-1.4.0
httplib2-0.22.0 itsdangerous-2.0.1 oauth2client-4.1.3 pyasn1-0.4.8
pyasn1-modules-0.2.8 python3-openid-3.2.0 rsa-4.9
WARNING: Running pip as the 'root' user can result in broken permissions and
conflicting behaviour with the system package manager. It is recommended to use
a virtual environment instead: https://pip.pypa.io/warnings/venv
WARNING: You are using pip version 21.2.4; however, version 23.0.1 is
available.
You should consider upgrading via the '/usr/local/bin/python -m pip install
--upgrade pip' command.
Upgrading DB schema...
logging was configured successfully
2023-03-22 22:31:29,925:INFO:superset.utils.logging_configurator:logging was
configured successfully
2023-03-22 22:31:29,930:INFO:root:Configured event logger of type <class
'superset.utils.log.DBEventLogger'>
We haven't found any Content Security Policy (CSP) defined in the
configurations. Please make sure to configure CSP using the TALISMAN_CONFIG key
or any other external software. Failing to configure CSP have serious security
implications. Check https://developer.mozilla.org/en-US/docs/Web/HTTP/CSP for
more information. You can disable this warning using the
CONTENT_SECURITY_POLICY_WARNING key.
2023-03-22 22:31:29,931:WARNING:superset.initialization:We haven't found any
Content Security Policy (CSP) defined in the configurations. Please make sure
to configure CSP using the TALISMAN_CONFIG key or any other external software.
Failing to configure CSP have serious security implications. Check
https://developer.mozilla.org/en-US/docs/Web/HTTP/CSP for more information. You
can disable this warning using the CONTENT_SECURITY_POLICY_WARNING key.
Falling back to the built-in cache, that stores data in the metadata
database, for the following cache: `FILTER_STATE_CACHE_CONFIG`. It is
recommended to use `RedisCache`, `MemcachedCache` or another dedicated caching
backend for production deployments
2023-03-22 22:31:29,934:WARNING:superset.utils.cache_manager:Falling back to
the built-in cache, that stores data in the metadata database, for the
following cache: `FILTER_STATE_CACHE_CONFIG`. It is recommended to use
`RedisCache`, `MemcachedCache` or another dedicated caching backend for
production deployments
Falling back to the built-in cache, that stores data in the metadata
database, for the following cache: `EXPLORE_FORM_DATA_CACHE_CONFIG`. It is
recommended to use `RedisCache`, `MemcachedCache` or another dedicated caching
backend for production deployments
2023-03-22 22:31:29,939:WARNING:superset.utils.cache_manager:Falling back to
the built-in cache, that stores data in the metadata database, for the
following cache: `EXPLORE_FORM_DATA_CACHE_CONFIG`. It is recommended to use
`RedisCache`, `MemcachedCache` or another dedicated caching backend for
production deployments
INFO [alembic.runtime.migration] Context impl PostgresqlImpl.
INFO [alembic.runtime.migration] Will assume transactional DDL.
Loaded your LOCAL configuration at [/app/pythonpath/superset_config.py]
```
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]