chore: Deprecates 3.0 consented feature flags (#23785)
This commit is contained in:
parent
09bd40bf15
commit
aa2edfc506
|
|
@ -27,17 +27,11 @@ These features are considered **unfinished** and should only be used on developm
|
||||||
|
|
||||||
[//]: # "PLEASE KEEP THE LIST SORTED ALPHABETICALLY"
|
[//]: # "PLEASE KEEP THE LIST SORTED ALPHABETICALLY"
|
||||||
|
|
||||||
- CLIENT_CACHE
|
|
||||||
- DASHBOARD_CACHE
|
|
||||||
- DASHBOARD_NATIVE_FILTERS_SET
|
|
||||||
- DISABLE_DATASET_SOURCE_EDIT
|
|
||||||
- DRILL_BY
|
- DRILL_BY
|
||||||
- ENABLE_ADVANCED_DATA_TYPES
|
- ENABLE_ADVANCED_DATA_TYPES
|
||||||
- ENABLE_EXPLORE_JSON_CSRF_PROTECTION
|
|
||||||
- ENABLE_TEMPLATE_REMOVE_FILTERS
|
- ENABLE_TEMPLATE_REMOVE_FILTERS
|
||||||
- KV_STORE
|
- KV_STORE
|
||||||
- PRESTO_EXPAND_DATA
|
- PRESTO_EXPAND_DATA
|
||||||
- REMOVE_SLICE_LEVEL_LABEL_COLORS
|
|
||||||
- SHARE_QUERIES_VIA_KV_STORE
|
- SHARE_QUERIES_VIA_KV_STORE
|
||||||
- TAGGING_SYSTEM
|
- TAGGING_SYSTEM
|
||||||
|
|
||||||
|
|
@ -51,8 +45,6 @@ These features are **finished** but currently being tested. They are usable, but
|
||||||
- ALLOW_FULL_CSV_EXPORT
|
- ALLOW_FULL_CSV_EXPORT
|
||||||
- CACHE_IMPERSONATION
|
- CACHE_IMPERSONATION
|
||||||
- CONFIRM_DASHBOARD_DIFF
|
- CONFIRM_DASHBOARD_DIFF
|
||||||
- DASHBOARD_EDIT_CHART_IN_NEW_TAB
|
|
||||||
- DASHBOARD_FILTERS_EXPERIMENTAL
|
|
||||||
- DASHBOARD_VIRTUALIZATION
|
- DASHBOARD_VIRTUALIZATION
|
||||||
- DRILL_BY
|
- DRILL_BY
|
||||||
- DRILL_TO_DETAIL
|
- DRILL_TO_DETAIL
|
||||||
|
|
@ -98,5 +90,12 @@ These features flags currently default to True and **will be removed in a future
|
||||||
|
|
||||||
[//]: # "PLEASE KEEP THE LIST SORTED ALPHABETICALLY"
|
[//]: # "PLEASE KEEP THE LIST SORTED ALPHABETICALLY"
|
||||||
|
|
||||||
|
- CLIENT_CACHE
|
||||||
|
- DASHBOARD_CACHE
|
||||||
|
- DASHBOARD_FILTERS_EXPERIMENTAL
|
||||||
- DASHBOARD_NATIVE_FILTERS
|
- DASHBOARD_NATIVE_FILTERS
|
||||||
|
- DASHBOARD_NATIVE_FILTERS_SET
|
||||||
|
- DISABLE_DATASET_SOURCE_EDIT
|
||||||
|
- ENABLE_EXPLORE_JSON_CSRF_PROTECTION
|
||||||
- GENERIC_CHART_AXES
|
- GENERIC_CHART_AXES
|
||||||
|
- REMOVE_SLICE_LEVEL_LABEL_COLORS
|
||||||
|
|
|
||||||
|
|
@ -24,6 +24,7 @@ assists people when migrating to a new version.
|
||||||
|
|
||||||
## Next
|
## Next
|
||||||
|
|
||||||
|
- [23785](https://github.com/apache/superset/pull/23785) Deprecated the following feature flags: `CLIENT_CACHE`, `DASHBOARD_CACHE`, `DASHBOARD_FILTERS_EXPERIMENTAL`, `DASHBOARD_NATIVE_FILTERS`, `DASHBOARD_NATIVE_FILTERS_SET`, `DISABLE_DATASET_SOURCE_EDIT`, `ENABLE_EXPLORE_JSON_CSRF_PROTECTION`, `REMOVE_SLICE_LEVEL_LABEL_COLORS`. It also removed `DASHBOARD_EDIT_CHART_IN_NEW_TAB` as the feature is supported without the need for a feature flag.
|
||||||
- [23652](https://github.com/apache/superset/pull/23652) Enables GENERIC_CHART_AXES feature flag by default.
|
- [23652](https://github.com/apache/superset/pull/23652) Enables GENERIC_CHART_AXES feature flag by default.
|
||||||
- [23226](https://github.com/apache/superset/pull/23226) Migrated endpoint `/estimate_query_cost/<int:database_id>` to `/api/v1/sqllab/estimate/`. Corresponding permissions are can estimate query cost on SQLLab. Make sure you add/replace the necessary permissions on any custom roles you may have.
|
- [23226](https://github.com/apache/superset/pull/23226) Migrated endpoint `/estimate_query_cost/<int:database_id>` to `/api/v1/sqllab/estimate/`. Corresponding permissions are can estimate query cost on SQLLab. Make sure you add/replace the necessary permissions on any custom roles you may have.
|
||||||
- [22809](https://github.com/apache/superset/pull/22809): Migrated endpoint `/superset/sql_json` and `/superset/results/` to `/api/v1/sqllab/execute/` and `/api/v1/sqllab/results/` respectively. Corresponding permissions are `can sql_json on Superset` to `can execute on SQLLab`, `can results on Superset` to `can results on SQLLab`. Make sure you add/replace the necessary permissions on any custom roles you may have.
|
- [22809](https://github.com/apache/superset/pull/22809): Migrated endpoint `/superset/sql_json` and `/superset/results/` to `/api/v1/sqllab/execute/` and `/api/v1/sqllab/results/` respectively. Corresponding permissions are `can sql_json on Superset` to `can execute on SQLLab`, `can results on Superset` to `can results on SQLLab`. Make sure you add/replace the necessary permissions on any custom roles you may have.
|
||||||
|
|
|
||||||
|
|
@ -25,7 +25,6 @@ export enum FeatureFlag {
|
||||||
ALLOW_FULL_CSV_EXPORT = 'ALLOW_FULL_CSV_EXPORT',
|
ALLOW_FULL_CSV_EXPORT = 'ALLOW_FULL_CSV_EXPORT',
|
||||||
CLIENT_CACHE = 'CLIENT_CACHE',
|
CLIENT_CACHE = 'CLIENT_CACHE',
|
||||||
DASHBOARD_CROSS_FILTERS = 'DASHBOARD_CROSS_FILTERS',
|
DASHBOARD_CROSS_FILTERS = 'DASHBOARD_CROSS_FILTERS',
|
||||||
DASHBOARD_EDIT_CHART_IN_NEW_TAB = 'DASHBOARD_EDIT_CHART_IN_NEW_TAB',
|
|
||||||
DASHBOARD_FILTERS_EXPERIMENTAL = 'DASHBOARD_FILTERS_EXPERIMENTAL',
|
DASHBOARD_FILTERS_EXPERIMENTAL = 'DASHBOARD_FILTERS_EXPERIMENTAL',
|
||||||
CONFIRM_DASHBOARD_DIFF = 'CONFIRM_DASHBOARD_DIFF',
|
CONFIRM_DASHBOARD_DIFF = 'CONFIRM_DASHBOARD_DIFF',
|
||||||
DASHBOARD_NATIVE_FILTERS = 'DASHBOARD_NATIVE_FILTERS',
|
DASHBOARD_NATIVE_FILTERS = 'DASHBOARD_NATIVE_FILTERS',
|
||||||
|
|
|
||||||
|
|
@ -303,18 +303,6 @@ test('Display cmd button in tooltip if running on MacOS', async () => {
|
||||||
).toBeInTheDocument();
|
).toBeInTheDocument();
|
||||||
});
|
});
|
||||||
|
|
||||||
test('Display correct tooltip when DASHBOARD_EDIT_CHART_IN_NEW_TAB is enabled', async () => {
|
|
||||||
window.featureFlags.DASHBOARD_EDIT_CHART_IN_NEW_TAB = true;
|
|
||||||
const props = createProps();
|
|
||||||
render(<SliceHeader {...props} />, { useRedux: true, useRouter: true });
|
|
||||||
userEvent.hover(screen.getByText('Vaccine Candidates per Phase'));
|
|
||||||
expect(
|
|
||||||
await screen.findByText(
|
|
||||||
'Click to edit Vaccine Candidates per Phase in a new tab',
|
|
||||||
),
|
|
||||||
).toBeInTheDocument();
|
|
||||||
});
|
|
||||||
|
|
||||||
test('Should not render click to edit prompt and run onExploreChart on click if supersetCanExplore=false', () => {
|
test('Should not render click to edit prompt and run onExploreChart on click if supersetCanExplore=false', () => {
|
||||||
const props = createProps({ supersetCanExplore: false });
|
const props = createProps({ supersetCanExplore: false });
|
||||||
const history = createMemoryHistory({
|
const history = createMemoryHistory({
|
||||||
|
|
|
||||||
|
|
@ -19,13 +19,7 @@
|
||||||
import cx from 'classnames';
|
import cx from 'classnames';
|
||||||
import React from 'react';
|
import React from 'react';
|
||||||
import PropTypes from 'prop-types';
|
import PropTypes from 'prop-types';
|
||||||
import {
|
import { styled, t, logging } from '@superset-ui/core';
|
||||||
styled,
|
|
||||||
t,
|
|
||||||
logging,
|
|
||||||
isFeatureEnabled,
|
|
||||||
FeatureFlag,
|
|
||||||
} from '@superset-ui/core';
|
|
||||||
import { isEqual } from 'lodash';
|
import { isEqual } from 'lodash';
|
||||||
import { withRouter } from 'react-router-dom';
|
import { withRouter } from 'react-router-dom';
|
||||||
|
|
||||||
|
|
@ -319,10 +313,7 @@ class Chart extends React.Component {
|
||||||
[URL_PARAMS.formDataKey.name]: key,
|
[URL_PARAMS.formDataKey.name]: key,
|
||||||
[URL_PARAMS.sliceId.name]: this.props.slice.slice_id,
|
[URL_PARAMS.sliceId.name]: this.props.slice.slice_id,
|
||||||
});
|
});
|
||||||
if (
|
if (isOpenInNewTab) {
|
||||||
isFeatureEnabled(FeatureFlag.DASHBOARD_EDIT_CHART_IN_NEW_TAB) ||
|
|
||||||
isOpenInNewTab
|
|
||||||
) {
|
|
||||||
window.open(url, '_blank', 'noreferrer');
|
window.open(url, '_blank', 'noreferrer');
|
||||||
} else {
|
} else {
|
||||||
this.props.history.push(url);
|
this.props.history.push(url);
|
||||||
|
|
|
||||||
|
|
@ -18,15 +18,10 @@
|
||||||
*/
|
*/
|
||||||
|
|
||||||
import React from 'react';
|
import React from 'react';
|
||||||
import { FeatureFlag, isFeatureEnabled, t } from '@superset-ui/core';
|
import { t } from '@superset-ui/core';
|
||||||
import { detectOS } from 'src/utils/common';
|
import { detectOS } from 'src/utils/common';
|
||||||
|
|
||||||
export const getSliceHeaderTooltip = (sliceName: string | undefined) => {
|
export const getSliceHeaderTooltip = (sliceName: string | undefined) => {
|
||||||
if (isFeatureEnabled(FeatureFlag.DASHBOARD_EDIT_CHART_IN_NEW_TAB)) {
|
|
||||||
return sliceName
|
|
||||||
? t('Click to edit %s in a new tab', sliceName)
|
|
||||||
: t('Click to edit chart.');
|
|
||||||
}
|
|
||||||
const isMac = detectOS() === 'MacOS';
|
const isMac = detectOS() === 'MacOS';
|
||||||
const firstLine = sliceName
|
const firstLine = sliceName
|
||||||
? t('Click to edit %s.', sliceName)
|
? t('Click to edit %s.', sliceName)
|
||||||
|
|
|
||||||
|
|
@ -388,8 +388,8 @@ LANGUAGES = {}
|
||||||
# will result in combined feature flags of { 'FOO': True, 'BAR': True, 'BAZ': True }
|
# will result in combined feature flags of { 'FOO': True, 'BAR': True, 'BAZ': True }
|
||||||
DEFAULT_FEATURE_FLAGS: Dict[str, bool] = {
|
DEFAULT_FEATURE_FLAGS: Dict[str, bool] = {
|
||||||
# Experimental feature introducing a client (browser) cache
|
# Experimental feature introducing a client (browser) cache
|
||||||
"CLIENT_CACHE": False,
|
"CLIENT_CACHE": False, # deprecated
|
||||||
"DISABLE_DATASET_SOURCE_EDIT": False,
|
"DISABLE_DATASET_SOURCE_EDIT": False, # deprecated
|
||||||
# When using a recent version of Druid that supports JOINs turn this on
|
# When using a recent version of Druid that supports JOINs turn this on
|
||||||
"DRUID_JOINS": False,
|
"DRUID_JOINS": False,
|
||||||
"DYNAMIC_PLUGINS": False,
|
"DYNAMIC_PLUGINS": False,
|
||||||
|
|
@ -404,7 +404,7 @@ DEFAULT_FEATURE_FLAGS: Dict[str, bool] = {
|
||||||
# When ENABLE_EXPLORE_JSON_CSRF_PROTECTION is set to true, your users cannot
|
# When ENABLE_EXPLORE_JSON_CSRF_PROTECTION is set to true, your users cannot
|
||||||
# make GET request to explore_json. explore_json accepts both GET and POST request.
|
# make GET request to explore_json. explore_json accepts both GET and POST request.
|
||||||
# See `PR 7935 <https://github.com/apache/superset/pull/7935>`_ for more details.
|
# See `PR 7935 <https://github.com/apache/superset/pull/7935>`_ for more details.
|
||||||
"ENABLE_EXPLORE_JSON_CSRF_PROTECTION": False,
|
"ENABLE_EXPLORE_JSON_CSRF_PROTECTION": False, # deprecated
|
||||||
"ENABLE_TEMPLATE_PROCESSING": False,
|
"ENABLE_TEMPLATE_PROCESSING": False,
|
||||||
"ENABLE_TEMPLATE_REMOVE_FILTERS": False,
|
"ENABLE_TEMPLATE_REMOVE_FILTERS": False,
|
||||||
# Allow for javascript controls components
|
# Allow for javascript controls components
|
||||||
|
|
@ -419,19 +419,19 @@ DEFAULT_FEATURE_FLAGS: Dict[str, bool] = {
|
||||||
"PRESTO_EXPAND_DATA": False,
|
"PRESTO_EXPAND_DATA": False,
|
||||||
# Exposes API endpoint to compute thumbnails
|
# Exposes API endpoint to compute thumbnails
|
||||||
"THUMBNAILS": False,
|
"THUMBNAILS": False,
|
||||||
"DASHBOARD_CACHE": False,
|
"DASHBOARD_CACHE": False, # deprecated
|
||||||
"REMOVE_SLICE_LEVEL_LABEL_COLORS": False,
|
"REMOVE_SLICE_LEVEL_LABEL_COLORS": False, # deprecated
|
||||||
"SHARE_QUERIES_VIA_KV_STORE": False,
|
"SHARE_QUERIES_VIA_KV_STORE": False,
|
||||||
"TAGGING_SYSTEM": False,
|
"TAGGING_SYSTEM": False,
|
||||||
"SQLLAB_BACKEND_PERSISTENCE": True,
|
"SQLLAB_BACKEND_PERSISTENCE": True,
|
||||||
"LISTVIEWS_DEFAULT_CARD_VIEW": False,
|
"LISTVIEWS_DEFAULT_CARD_VIEW": False,
|
||||||
# When True, this escapes HTML (rather than rendering it) in Markdown components
|
# When True, this escapes HTML (rather than rendering it) in Markdown components
|
||||||
"ESCAPE_MARKDOWN_HTML": False,
|
"ESCAPE_MARKDOWN_HTML": False,
|
||||||
"DASHBOARD_NATIVE_FILTERS": True,
|
"DASHBOARD_NATIVE_FILTERS": True, # deprecated
|
||||||
"DASHBOARD_CROSS_FILTERS": False,
|
"DASHBOARD_CROSS_FILTERS": False,
|
||||||
# Feature is under active development and breaking changes are expected
|
# Feature is under active development and breaking changes are expected
|
||||||
"DASHBOARD_NATIVE_FILTERS_SET": False,
|
"DASHBOARD_NATIVE_FILTERS_SET": False, # deprecated
|
||||||
"DASHBOARD_FILTERS_EXPERIMENTAL": False,
|
"DASHBOARD_FILTERS_EXPERIMENTAL": False, # deprecated
|
||||||
"DASHBOARD_VIRTUALIZATION": False,
|
"DASHBOARD_VIRTUALIZATION": False,
|
||||||
"GLOBAL_ASYNC_QUERIES": False,
|
"GLOBAL_ASYNC_QUERIES": False,
|
||||||
"VERSIONED_EXPORT": True,
|
"VERSIONED_EXPORT": True,
|
||||||
|
|
@ -452,10 +452,9 @@ DEFAULT_FEATURE_FLAGS: Dict[str, bool] = {
|
||||||
# Allow users to export full CSV of table viz type.
|
# Allow users to export full CSV of table viz type.
|
||||||
# This could cause the server to run out of memory or compute.
|
# This could cause the server to run out of memory or compute.
|
||||||
"ALLOW_FULL_CSV_EXPORT": False,
|
"ALLOW_FULL_CSV_EXPORT": False,
|
||||||
"GENERIC_CHART_AXES": True,
|
"GENERIC_CHART_AXES": True, # deprecated
|
||||||
"ALLOW_ADHOC_SUBQUERY": False,
|
"ALLOW_ADHOC_SUBQUERY": False,
|
||||||
"USE_ANALAGOUS_COLORS": False,
|
"USE_ANALAGOUS_COLORS": False,
|
||||||
"DASHBOARD_EDIT_CHART_IN_NEW_TAB": False,
|
|
||||||
# Apply RLS rules to SQL Lab queries. This requires parsing and manipulating the
|
# Apply RLS rules to SQL Lab queries. This requires parsing and manipulating the
|
||||||
# query, and might break queries and/or allow users to bypass RLS. Use with care!
|
# query, and might break queries and/or allow users to bypass RLS. Use with care!
|
||||||
"RLS_IN_SQLLAB": False,
|
"RLS_IN_SQLLAB": False,
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue