refactor: Removes the deprecated ENABLE_TEMPLATE_REMOVE_FILTERS feature flag (#26345)

This commit is contained in:
Michael S. Molina 2024-01-18 09:03:03 -03:00 committed by GitHub
parent 6443001cef
commit b06ab7d8e3
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
5 changed files with 4 additions and 7 deletions

View File

@ -88,7 +88,6 @@ These features flags currently default to True and **will be removed in a future
- DASHBOARD_NATIVE_FILTERS
- ENABLE_EXPLORE_JSON_CSRF_PROTECTION
- ENABLE_JAVASCRIPT_CONTROLS
- ENABLE_TEMPLATE_REMOVE_FILTERS
- GENERIC_CHART_AXES
- KV_STORE
- VERSIONED_EXPORT

View File

@ -30,6 +30,7 @@ assists people when migrating to a new version.
### Breaking Changes
- [26345](https://github.com/apache/superset/issues/26345): Removes the deprecated `ENABLE_TEMPLATE_REMOVE_FILTERS` feature flag. The previous value of the feature flag was `True` and now the feature is permanently enabled.
- [26346](https://github.com/apache/superset/issues/26346): Removes the deprecated `REMOVE_SLICE_LEVEL_LABEL_COLORS` feature flag. The previous value of the feature flag was `False` and now the feature is permanently removed.
- [26348](https://github.com/apache/superset/issues/26348): Removes the deprecated `CLIENT_CACHE` feature flag. The previous value of the feature flag was `False` and now the feature is permanently removed.
- [26349](https://github.com/apache/superset/issues/26349): Removes the deprecated `DASHBOARD_CACHE` feature flag. The previous value of the feature flag was `False` and now the feature is permanently removed.

View File

@ -44,7 +44,6 @@ export enum FeatureFlag {
/** @deprecated */
ENABLE_JAVASCRIPT_CONTROLS = 'ENABLE_JAVASCRIPT_CONTROLS',
ENABLE_TEMPLATE_PROCESSING = 'ENABLE_TEMPLATE_PROCESSING',
ENABLE_TEMPLATE_REMOVE_FILTERS = 'ENABLE_TEMPLATE_REMOVE_FILTERS',
ESCAPE_MARKDOWN_HTML = 'ESCAPE_MARKDOWN_HTML',
ESTIMATE_QUERY_COST = 'ESTIMATE_QUERY_COST',
GENERIC_CHART_AXES = 'GENERIC_CHART_AXES',

View File

@ -418,7 +418,6 @@ DEFAULT_FEATURE_FLAGS: dict[str, bool] = {
# See `PR 7935 <https://github.com/apache/superset/pull/7935>`_ for more details.
"ENABLE_EXPLORE_JSON_CSRF_PROTECTION": False, # deprecated
"ENABLE_TEMPLATE_PROCESSING": False,
"ENABLE_TEMPLATE_REMOVE_FILTERS": True, # deprecated
# Allow for javascript controls components
# this enables programmers to customize certain charts (like the
# geospatial ones) by inputting javascript in controls. This exposes

View File

@ -1760,10 +1760,9 @@ class ExploreMixin: # pylint: disable=too-many-public-methods
col_obj = columns_by_name.get(cast(str, flt_col))
filter_grain = flt.get("grain")
if is_feature_enabled("ENABLE_TEMPLATE_REMOVE_FILTERS"):
if get_column_name(flt_col) in removed_filters:
# Skip generating SQLA filter when the jinja template handles it.
continue
if get_column_name(flt_col) in removed_filters:
# Skip generating SQLA filter when the jinja template handles it.
continue
if col_obj or sqla_col is not None:
if sqla_col is not None: