Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: Row limit hardcoded #26807

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -243,10 +243,10 @@ const row_limit: SharedControlConfig<'SelectControl'> = {
freeForm: true,
label: t('Row limit'),
clearable: false,
mapStateToProps: state => ({ maxValue: state?.common?.conf?.SQL_MAX_ROW }),
validators: [
legacyValidateInteger,
(v, state) =>
validateMaxValue(v, state?.common?.conf?.SQL_MAX_ROW || DEFAULT_MAX_ROW),
(v, state) => validateMaxValue(v, state?.maxValue || DEFAULT_MAX_ROW),
],
default: 10000,
choices: formatSelectOptions(ROW_LIMIT_OPTIONS),
Expand Down
2 changes: 1 addition & 1 deletion tests/integration_tests/celery_tests.py
Original file line number Diff line number Diff line change
Expand Up @@ -344,7 +344,7 @@ def test_run_async_cta_query_with_lower_limit(test_client, ctas_method):
assert QUERY == query.sql

assert query.rows == (1 if backend() == "presto" else 0)
assert query.limit == 10000
assert query.limit == 50000
assert query.select_as_cta
assert query.select_as_cta_used

Expand Down
2 changes: 1 addition & 1 deletion tests/integration_tests/superset_test_config.py
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@
PRESTO_POLL_INTERVAL = 0.1
HIVE_POLL_INTERVAL = 0.1

SQL_MAX_ROW = 10000
SQL_MAX_ROW = 50000
SQLLAB_CTAS_NO_LIMIT = True # SQL_MAX_ROW will not take effect for the CTA queries
FEATURE_FLAGS = {
**FEATURE_FLAGS,
Expand Down
Loading