Skip to content

Commit 0df16b3

Browse files
author
Lily Kuang
committed
Merge remote-tracking branch 'origin/master' into lily/upgrade-react-17
2 parents 39649b0 + 1670275 commit 0df16b3

File tree

141 files changed

+2504
-1988
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

141 files changed

+2504
-1988
lines changed

.asf.yaml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -66,12 +66,12 @@ github:
6666
- cypress-matrix (3, chrome)
6767
- docker-build
6868
- frontend-build
69-
- pre-commit (3.8)
70-
- python-lint (3.8)
71-
- test-mysql (3.8)
72-
- test-postgres (3.8)
69+
- pre-commit (3.9)
70+
- python-lint (3.9)
71+
- test-mysql (3.9)
7372
- test-postgres (3.9)
74-
- test-sqlite (3.8)
73+
- test-postgres (3.10)
74+
- test-sqlite (3.9)
7575

7676
required_pull_request_reviews:
7777
dismiss_stale_reviews: false

.github/workflows/codeql-analysis.yml

Lines changed: 50 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,50 @@
1+
name: "CodeQL"
2+
3+
on:
4+
push:
5+
branches: [ "master" ]
6+
paths:
7+
- 'superset/**'
8+
pull_request:
9+
# The branches below must be a subset of the branches above
10+
branches: [ "master" ]
11+
paths:
12+
- 'superset/**'
13+
schedule:
14+
- cron: '0 4 * * *'
15+
16+
jobs:
17+
analyze:
18+
name: Analyze
19+
runs-on: ubuntu-22.04
20+
permissions:
21+
actions: read
22+
contents: read
23+
security-events: write
24+
25+
strategy:
26+
fail-fast: false
27+
matrix:
28+
language: [ 'python', 'javascript' ]
29+
# Learn more about CodeQL language support at https://aka.ms/codeql-docs/language-support
30+
31+
steps:
32+
- name: Checkout repository
33+
uses: actions/checkout@v3
34+
35+
# Initializes the CodeQL tools for scanning.
36+
- name: Initialize CodeQL
37+
uses: github/codeql-action/init@v2
38+
with:
39+
languages: ${{ matrix.language }}
40+
# If you wish to specify custom queries, you can do so here or in a config file.
41+
# By default, queries listed here will override any specified in a config file.
42+
# Prefix the list here with "+" to use these queries and those in the config file.
43+
44+
# For more details on CodeQL's query packs, refer to: https://docs.github.com/en/code-security/code-scanning/automatically-scanning-your-code-for-vulnerabilities-and-errors/configuring-code-scanning#using-queries-in-ql-packs
45+
# queries: security-extended,security-and-quality
46+
47+
- name: Perform CodeQL Analysis
48+
uses: github/codeql-action/analyze@v2
49+
with:
50+
category: "/language:${{matrix.language}}"
Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
# Dependency Review Action
2+
#
3+
# This Action will scan dependency manifest files that change as part of a Pull Request, surfacing known-vulnerable versions of the packages declared or updated in the PR. Once installed, if the workflow run is marked as required, PRs introducing known-vulnerable packages will be blocked from merging.
4+
#
5+
# Source repository: https://github.com/actions/dependency-review-action
6+
# Public documentation: https://docs.github.com/en/code-security/supply-chain-security/understanding-your-software-supply-chain/about-dependency-review#dependency-review-enforcement
7+
name: 'Dependency Review'
8+
on: [pull_request]
9+
10+
permissions:
11+
contents: read
12+
13+
jobs:
14+
dependency-review:
15+
runs-on: ubuntu-latest
16+
steps:
17+
- name: 'Checkout Repository'
18+
uses: actions/checkout@v3
19+
- name: 'Dependency Review'
20+
uses: actions/dependency-review-action@v2
21+
with:
22+
fail-on-severity: high
23+
# compatible/incompatible licenses addressed here: https://www.apache.org/legal/resolved.html
24+
# find SPDX identifiers here: https://spdx.org/licenses/
25+
deny-licenses: MS-LPL, BUSL-1.1, QPL-1.0, Sleepycat, SSPL-1.0, CPOL-1.02, AGPL-3.0, GPL-1.0+, BSD-4-Clause-UC, NPL-1.0, NPL-1.1, JSON

.github/workflows/docker_build_push.sh

Lines changed: 6 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -50,24 +50,23 @@ docker build --target lean \
5050
-t "${REPO_NAME}:${SHA}" \
5151
-t "${REPO_NAME}:${REFSPEC}" \
5252
-t "${REPO_NAME}:${LATEST_TAG}" \
53-
--build-arg PY_VER="3.8-slim"\
5453
--label "sha=${SHA}" \
5554
--label "built_at=$(date)" \
5655
--label "target=lean" \
5756
--label "build_actor=${GITHUB_ACTOR}" \
5857
.
5958

6059
#
61-
# Build the "lean39" image
60+
# Build the "lean310" image
6261
#
6362
docker build --target lean \
64-
-t "${REPO_NAME}:${SHA}-py39" \
65-
-t "${REPO_NAME}:${REFSPEC}-py39" \
66-
-t "${REPO_NAME}:${LATEST_TAG}-py39" \
67-
--build-arg PY_VER="3.9-slim"\
63+
-t "${REPO_NAME}:${SHA}-py310" \
64+
-t "${REPO_NAME}:${REFSPEC}-py310" \
65+
-t "${REPO_NAME}:${LATEST_TAG}-py310" \
66+
--build-arg PY_VER="3.10-slim"\
6867
--label "sha=${SHA}" \
6968
--label "built_at=$(date)" \
70-
--label "target=lean39" \
69+
--label "target=lean310" \
7170
--label "build_actor=${GITHUB_ACTOR}" \
7271
.
7372

.github/workflows/superset-applitool-cypress.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ jobs:
6060
- name: Setup Python
6161
uses: actions/setup-python@v4
6262
with:
63-
python-version: "3.8"
63+
python-version: "3.9"
6464
- name: OS dependencies
6565
uses: ./.github/actions/cached-dependencies
6666
with:

.github/workflows/superset-cli.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ jobs:
1313
runs-on: ubuntu-20.04
1414
strategy:
1515
matrix:
16-
python-version: [3.9]
16+
python-version: ["3.9"]
1717
env:
1818
PYTHONPATH: ${{ github.workspace }}
1919
SUPERSET_CONFIG: tests.integration_tests.superset_test_config

.github/workflows/superset-e2e.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,7 @@ jobs:
6969
if: steps.check.outcome == 'failure'
7070
uses: actions/setup-python@v4
7171
with:
72-
python-version: "3.8"
72+
python-version: "3.9"
7373
- name: OS dependencies
7474
if: steps.check.outcome == 'failure'
7575
uses: ./.github/actions/cached-dependencies

.github/workflows/superset-helm-lint.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ jobs:
2222

2323
- uses: actions/setup-python@v4
2424
with:
25-
python-version: 3.8
25+
python-version: "3.9"
2626

2727
- name: Set up chart-testing
2828
uses: ./.github/actions/chart-testing-action

.github/workflows/superset-python-integrationtest.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ jobs:
1414
runs-on: ubuntu-20.04
1515
strategy:
1616
matrix:
17-
python-version: [3.8]
17+
python-version: ["3.9"]
1818
env:
1919
PYTHONPATH: ${{ github.workspace }}
2020
SUPERSET_CONFIG: tests.integration_tests.superset_test_config
@@ -80,7 +80,7 @@ jobs:
8080
runs-on: ubuntu-20.04
8181
strategy:
8282
matrix:
83-
python-version: [3.8, 3.9]
83+
python-version: ["3.9", "3.10"]
8484
env:
8585
PYTHONPATH: ${{ github.workspace }}
8686
SUPERSET_CONFIG: tests.integration_tests.superset_test_config
@@ -147,7 +147,7 @@ jobs:
147147
runs-on: ubuntu-20.04
148148
strategy:
149149
matrix:
150-
python-version: [3.8]
150+
python-version: ["3.9"]
151151
env:
152152
PYTHONPATH: ${{ github.workspace }}
153153
SUPERSET_CONFIG: tests.integration_tests.superset_test_config

.github/workflows/superset-python-misc.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ jobs:
1414
runs-on: ubuntu-20.04
1515
strategy:
1616
matrix:
17-
python-version: [3.8]
17+
python-version: ["3.9"]
1818
steps:
1919
- name: "Checkout ${{ github.ref }} ( ${{ github.sha }} )"
2020
uses: actions/checkout@v3
@@ -54,7 +54,7 @@ jobs:
5454
runs-on: ubuntu-20.04
5555
strategy:
5656
matrix:
57-
python-version: [3.8]
57+
python-version: ["3.9"]
5858
steps:
5959
- name: "Checkout ${{ github.ref }} ( ${{ github.sha }} )"
6060
uses: actions/checkout@v3
@@ -95,7 +95,7 @@ jobs:
9595
runs-on: ubuntu-20.04
9696
strategy:
9797
matrix:
98-
python-version: [3.8]
98+
python-version: ["3.9"]
9999
steps:
100100
- name: "Checkout ${{ github.ref }} ( ${{ github.sha }} )"
101101
uses: actions/checkout@v3

.github/workflows/superset-python-presto-hive.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ jobs:
1414
runs-on: ubuntu-20.04
1515
strategy:
1616
matrix:
17-
python-version: [3.8]
17+
python-version: ["3.9"]
1818
env:
1919
PYTHONPATH: ${{ github.workspace }}
2020
SUPERSET_CONFIG: tests.integration_tests.superset_test_config
@@ -91,7 +91,7 @@ jobs:
9191
runs-on: ubuntu-20.04
9292
strategy:
9393
matrix:
94-
python-version: [3.8]
94+
python-version: ["3.9"]
9595
env:
9696
PYTHONPATH: ${{ github.workspace }}
9797
SUPERSET_CONFIG: tests.integration_tests.superset_test_config

.github/workflows/superset-python-unittest.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ jobs:
1414
runs-on: ubuntu-20.04
1515
strategy:
1616
matrix:
17-
python-version: [3.8, 3.9]
17+
python-version: ["3.9", "3.10"]
1818
env:
1919
PYTHONPATH: ${{ github.workspace }}
2020
steps:

.github/workflows/superset-translations.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ jobs:
3535
runs-on: ubuntu-20.04
3636
strategy:
3737
matrix:
38-
python-version: [3.8]
38+
python-version: ["3.9"]
3939
steps:
4040
- name: "Checkout ${{ github.ref }} ( ${{ github.sha }} )"
4141
uses: actions/checkout@v3

.pre-commit-config.yaml

Lines changed: 14 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,11 +20,23 @@ repos:
2020
hooks:
2121
- id: isort
2222
- repo: https://github.com/pre-commit/mirrors-mypy
23-
rev: v1.0.1
23+
rev: v1.3.0
2424
hooks:
2525
- id: mypy
2626
args: [--check-untyped-defs]
27-
additional_dependencies: [types-all]
27+
additional_dependencies:
28+
[
29+
types-simplejson,
30+
types-python-dateutil,
31+
types-requests,
32+
types-redis,
33+
types-pytz,
34+
types-croniter,
35+
types-PyYAML,
36+
types-setuptools,
37+
types-paramiko,
38+
types-Markdown,
39+
]
2840
- repo: https://github.com/peterdemin/pip-compile-multi
2941
rev: v2.6.2
3042
hooks:

.pylintrc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -300,7 +300,7 @@ ignore-mixin-members=yes
300300
# (useful for modules/projects where namespaces are manipulated during runtime
301301
# and thus existing member attributes cannot be deduced by static analysis. It
302302
# supports qualified module names, as well as Unix pattern matching.
303-
ignored-modules=numpy,pandas,alembic.op,sqlalchemy,alembic.context,flask_appbuilder.security.sqla.PermissionView.role,flask_appbuilder.Model.metadata,flask_appbuilder.Base.metadata,distutils
303+
ignored-modules=numpy,pandas,alembic.op,sqlalchemy,alembic.context,flask_appbuilder.security.sqla.PermissionView.role,flask_appbuilder.Model.metadata,flask_appbuilder.Base.metadata
304304

305305
# List of class names for which member attributes should not be checked (useful
306306
# for classes with dynamically set attributes). This supports the use of

Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818
######################################################################
1919
# Node stage to deal with static asset construction
2020
######################################################################
21-
ARG PY_VER=3.8.16-slim
21+
ARG PY_VER=3.9.16-slim
2222

2323
# if BUILDPLATFORM is null, set it to 'amd64' (or leave as is otherwise).
2424
ARG BUILDPLATFORM=${BUILDPLATFORM:-amd64}

Makefile

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -15,8 +15,8 @@
1515
# limitations under the License.
1616
#
1717

18-
# Python version installed; we need 3.8-3.11
19-
PYTHON=`command -v python3.11 || command -v python3.10 || command -v python3.9 || command -v python3.8`
18+
# Python version installed; we need 3.9-3.11
19+
PYTHON=`command -v python3.11 || command -v python3.10 || command -v python3.9`
2020

2121
.PHONY: install superset venv pre-commit
2222

@@ -70,7 +70,7 @@ update-js:
7070

7171
venv:
7272
# Create a virtual environment and activate it (recommended)
73-
if ! [ -x "${PYTHON}" ]; then echo "You need Python 3.8, 3.9, 3.10 or 3.11 installed"; exit 1; fi
73+
if ! [ -x "${PYTHON}" ]; then echo "You need Python 3.9, 3.10 or 3.11 installed"; exit 1; fi
7474
test -d venv || ${PYTHON} -m venv venv # setup a python3 virtualenv
7575
. venv/bin/activate
7676

RESOURCES/FEATURE_FLAGS.md

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,6 @@ These features are considered **unfinished** and should only be used on developm
2727

2828
[//]: # "PLEASE KEEP THE LIST SORTED ALPHABETICALLY"
2929

30-
- DRILL_BY
3130
- ENABLE_ADVANCED_DATA_TYPES
3231
- ENABLE_TEMPLATE_REMOVE_FILTERS
3332
- KV_STORE
@@ -74,8 +73,6 @@ These features flags are **safe for production**. They have been tested and will
7473
- DRUID_JOINS
7574
- EMBEDDABLE_CHARTS
7675
- EMBEDDED_SUPERSET
77-
- ENABLE_DND_WITH_CLICK_UX
78-
- ENABLE_EXPLORE_DRAG_AND_DROP
7976
- ENABLE_TEMPLATE_PROCESSING
8077
- ESCAPE_MARKDOWN_HTML
8178
- LISTVIEWS_DEFAULT_CARD_VIEW
@@ -96,6 +93,7 @@ These features flags currently default to True and **will be removed in a future
9693
- DASHBOARD_NATIVE_FILTERS
9794
- DASHBOARD_NATIVE_FILTERS_SET
9895
- DISABLE_DATASET_SOURCE_EDIT
96+
- ENABLE_EXPLORE_DRAG_AND_DROP
9997
- ENABLE_EXPLORE_JSON_CSRF_PROTECTION
10098
- GENERIC_CHART_AXES
10199
- REMOVE_SLICE_LEVEL_LABEL_COLORS

UPDATING.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -46,6 +46,7 @@ assists people when migrating to a new version.
4646
- [21163](https://github.com/apache/superset/pull/21163): The time grain will be decoupled from the time filter column and the time grain control will move below the X-Axis control when `GENERIC_CHART_AXES` feature flags set to `True`. The time grain will be applied on the time column in the column-like controls(x axis, dimensions) instead of the time column in the time section.
4747
- [21284](https://github.com/apache/superset/pull/21284): The non-functional `MAX_TABLE_NAMES` config key has been removed.
4848
- [21794](https://github.com/apache/superset/pull/21794): Deprecates the undocumented `PRESTO_SPLIT_VIEWS_FROM_TABLES` feature flag. Now for Presto, like other engines, only physical tables are treated as tables.
49+
- [23890](https://github.com/apache/superset/pull/23890): Removes Python 3.8 support.
4950

5051
### Breaking Changes
5152

docs/docs/contributing/local-backend.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ version: 1
1212
Make sure your machine meets the [OS dependencies](https://superset.apache.org/docs/installation/installing-superset-from-scratch#os-dependencies) before following these steps.
1313
You also need to install MySQL or [MariaDB](https://mariadb.com/downloads).
1414

15-
Ensure that you are using Python version 3.8 or 3.9, then proceed with:
15+
Ensure that you are using Python version 3.9 or 3.10, then proceed with:
1616

1717
```bash
1818
# Create a virtual environment and activate it (recommended)

docs/docs/installation/running-on-kubernetes.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -142,7 +142,7 @@ connect to those datasources in your Superset installation:
142142
bootstrapScript: |
143143
#!/bin/bash
144144
pip install psycopg2==2.9.6 \
145-
sqlalchemy-bigquery==1.5.0 \
145+
sqlalchemy-bigquery==1.6.1 \
146146
elasticsearch-dbapi==0.2.5 &&\
147147
if [ ! -f ~/bootstrap ]; then echo "Running Superset with uid {{ .Values.runAsUser }}" > ~/bootstrap; fi
148148
```

docs/docs/installation/setup-ssh-tunneling.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ version: 1
99

1010
1. Turn on feature flag
1111
- Change [`SSH_TUNNELING`](https://github.com/apache/superset/blob/eb8386e3f0647df6d1bbde8b42073850796cc16f/superset/config.py#L489) to `True`
12-
- If you want to add more security when establishing the tunnel we allow users to overwrite the `SSHTunnelManager` class (here)[https://github.com/apache/superset/blob/eb8386e3f0647df6d1bbde8b42073850796cc16f/superset/config.py#L507]
12+
- If you want to add more security when establishing the tunnel we allow users to overwrite the `SSHTunnelManager` class [here](https://github.com/apache/superset/blob/eb8386e3f0647df6d1bbde8b42073850796cc16f/superset/config.py#L507)
1313
- You can also set the [`SSH_TUNNEL_LOCAL_BIND_ADDRESS`](https://github.com/apache/superset/blob/eb8386e3f0647df6d1bbde8b42073850796cc16f/superset/config.py#L508) this the host address where the tunnel will be accessible on your VPC
1414

1515
2. Create database w/ ssh tunnel enabled

0 commit comments

Comments
 (0)