diff --git a/superset/assets/javascripts/explore/stores/visTypes.js b/superset/assets/javascripts/explore/stores/visTypes.js index 85aeff6e59a61..68991e35babf1 100644 --- a/superset/assets/javascripts/explore/stores/visTypes.js +++ b/superset/assets/javascripts/explore/stores/visTypes.js @@ -798,6 +798,14 @@ const visTypes = { ], }, ], + controlOverrides: { + all_columns_x: { + validators: [v.nonEmpty], + }, + all_columns_y: { + validators: [v.nonEmpty], + }, + }, }, horizon: { diff --git a/superset/cli.py b/superset/cli.py index 46b0ca794be77..f6163bb140b09 100755 --- a/superset/cli.py +++ b/superset/cli.py @@ -192,7 +192,7 @@ def worker(workers): celery_app.conf.update(CELERYD_CONCURRENCY=workers) elif config.get("SUPERSET_CELERY_WORKERS"): celery_app.conf.update( - worker_concurrency=config.get("SUPERSET_CELERY_WORKERS")) + CELERYD_CONCURRENCY=config.get("SUPERSET_CELERY_WORKERS")) worker = celery_worker.worker(app=celery_app) worker.run() diff --git a/superset/views/core.py b/superset/views/core.py index 600207702948b..b03fef9608ad6 100755 --- a/superset/views/core.py +++ b/superset/views/core.py @@ -1375,7 +1375,7 @@ def testconn(self): .get('connect_args', {})) engine = create_engine(uri, connect_args=connect_args) engine.connect() - return json.dumps(engine.table_names(), indent=4) + return json_success(json.dumps(engine.table_names(), indent=4)) except Exception as e: logging.exception(e) return json_error_response(( diff --git a/tests/core_tests.py b/tests/core_tests.py index 7ff48a9081a8c..f3e98873a63fa 100644 --- a/tests/core_tests.py +++ b/tests/core_tests.py @@ -284,6 +284,7 @@ def test_testconn(self): }) response = self.client.post('/superset/testconn', data=data, content_type='application/json') assert response.status_code == 200 + assert response.headers['Content-Type'] == 'application/json' # validate that the endpoint works with the decrypted sqlalchemy uri data = json.dumps({ @@ -292,6 +293,7 @@ def test_testconn(self): }) response = self.client.post('/superset/testconn', data=data, content_type='application/json') assert response.status_code == 200 + assert response.headers['Content-Type'] == 'application/json' def test_databaseview_edit(self, username='admin'): # validate that sending a password-masked uri does not over-write the decrypted uri