Skip to content

Commit

Permalink
Pulling Upstream refs/tags/4.1.1 into ortege (#46)
Browse files Browse the repository at this point in the history
👑 *An automated PR to sync with upstream*

Co-authored-by: josedev-union josedev-union@users.noreply.github.com
  • Loading branch information
josedev-union authored Dec 4, 2024
2 parents 96a924d + ed45539 commit 0fc4fe2
Show file tree
Hide file tree
Showing 3,120 changed files with 247,712 additions and 329,886 deletions.
The diff you're trying to view is too large. We only load the first 3000 changed files.
27 changes: 13 additions & 14 deletions .asf.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -63,24 +63,23 @@ github:
# combination here.
contexts:
- lint-check
- cypress-matrix (0, chrome)
- cypress-matrix (1, chrome)
- cypress-matrix (2, chrome)
- cypress-matrix (3, chrome)
- cypress-matrix (4, chrome)
- cypress-matrix (5, chrome)
- frontend-build
- pre-commit (3.9)
- python-lint (3.9)
- test-mysql (3.9)
- test-postgres (3.9)
- test-postgres (3.10)
- test-sqlite (3.9)
- docker-build (dev, linux/amd64)
- docker-build (lean, linux/amd64)
- docker-build (py310, linux/arm64)
- docker-build (py310, linux/amd64)
- docker-build (websocket, linux/arm64)
- docker-build (websocket, linux/amd64)
- docker-build (dockerize, linux/arm64)
- docker-build (dockerize, linux/amd64)
- pre-commit
- python-lint
- test-mysql
- test-postgres (current)
- test-postgres (next)
- test-postgres-hive
- test-postgres-presto
- test-sqlite
- unit-tests (current)
- unit-tests (next)

required_pull_request_reviews:
dismiss_stale_reviews: false
Expand Down
1 change: 1 addition & 0 deletions .gitattributes
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
docker/**/*.sh text eol=lf
*.svg binary
4 changes: 1 addition & 3 deletions .github/CODEOWNERS
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,6 @@
/.asf.yaml @villebro @geido @eschutho @rusackas @betodealmeida @nytai @mistercrunch @craig-rueda @john-bodley @kgabryje @dpgaspar

# Maps are a finnicky contribution process we care about

**/*.geojson @villebro @rusackas
/superset-frontend/plugins/legacy-plugin-chart-country-map/ @villebro @rusackas

# Translations are a finnicky contribution that we care about
/superset/translations/ @villebro @rusackas @michael-s-molina
5 changes: 3 additions & 2 deletions .github/ISSUE_TEMPLATE/bug-report.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ body:
value: |
Hello Superset Community member! Please keep things tidy by putting your post in the proper place:
🚨 Reporting a security issue: send an email to security@superset.apache.org. DO NOT USE GITHUB ISSUES TO REPORT SECURITY PROBLEMS.
🐛 Reporting a bug: use this form.
🙏 Asking a question or getting help: post in the [Superset Slack chat](http://bit.ly/join-superset-slack) or [GitHub Discussions](https://github.com/apache/superset/discussions) under "Q&A / Help".
💡 Requesting a new feature: Search [GitHub Discussions](https://github.com/apache/superset/discussions) to see if it exists already. If not, add a new post there under "Ideas".
Expand Down Expand Up @@ -45,8 +46,8 @@ body:
label: Superset version
options:
- master / latest-dev
- "3.1.0"
- "3.0.4"
- "4.0.2"
- "3.1.3"
validations:
required: true
- type: dropdown
Expand Down
31 changes: 31 additions & 0 deletions .github/actions/change-detector/action.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
name: 'Change Detector'
description: 'Detects file changes for pull request and push events'
inputs:
token:
description: 'GitHub token for authentication'
required: true
outputs:
python:
description: 'Whether Python-related files were changed'
value: ${{ steps.change-detector.outputs.python }}
frontend:
description: 'Whether frontend-related files were changed'
value: ${{ steps.change-detector.outputs.frontend }}
docker:
description: 'Whether docker-related files were changed'
value: ${{ steps.change-detector.outputs.docker }}
docs:
description: 'Whether docs-related files were changed'
value: ${{ steps.change-detector.outputs.docs }}
runs:
using: 'composite'
steps:
- name: Detect file changes
id: change-detector
run: |
python --version
python scripts/change_detector.py
shell: bash
env:
GITHUB_TOKEN: ${{ inputs.token }}
GITHUB_OUTPUT: ${{ github.output }}
53 changes: 53 additions & 0 deletions .github/actions/setup-backend/action.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
name: 'Setup Python Environment'
description: 'Set up Python and install dependencies with optional configurations.'
inputs:
python-version:
description: 'Python version to set up. Accepts a version number, "current", or "next".'
required: true
default: 'current'
cache:
description: 'Cache dependencies. Options: pip'
required: false
default: 'pip'
requirements-type:
description: 'Type of requirements to install. Options: base, development, default'
required: false
default: 'dev'
install-superset:
description: 'Whether to install Superset itself. If false, only python is installed'
required: false
default: 'true'

runs:
using: 'composite'
steps:
- name: Interpret Python Version
id: set-python-version
shell: bash
run: |
if [ "${{ inputs.python-version }}" = "current" ]; then
echo "PYTHON_VERSION=3.10" >> $GITHUB_ENV
elif [ "${{ inputs.python-version }}" = "next" ]; then
echo "PYTHON_VERSION=3.11" >> $GITHUB_ENV
elif [ "${{ inputs.python-version }}" = "previous" ]; then
echo "PYTHON_VERSION=3.9" >> $GITHUB_ENV
else
echo "PYTHON_VERSION=${{ inputs.python-version }}" >> $GITHUB_ENV
fi
- name: Set up Python ${{ env.PYTHON_VERSION }}
uses: actions/setup-python@v5
with:
python-version: ${{ env.PYTHON_VERSION }}
cache: ${{ inputs.cache }}
- name: Install dependencies
run: |
if [ "${{ inputs.install-superset }}" = "true" ]; then
sudo apt-get update && sudo apt-get -y install libldap2-dev libsasl2-dev
pip install --upgrade pip setuptools wheel
if [ "${{ inputs.requirements-type }}" = "dev" ]; then
pip install -r requirements/development.txt
elif [ "${{ inputs.requirements-type }}" = "base" ]; then
pip install -r requirements/base.txt
fi
fi
shell: bash
40 changes: 40 additions & 0 deletions .github/actions/setup-supersetbot/action.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
name: 'Setup supersetbot'
description: 'Sets up supersetbot npm lib from the repo or npm'
inputs:
from-npm:
description: 'Install from npm instead of local setup'
required: false
default: 'true' # Defaults to using the local setup
runs:
using: 'composite'
steps:

- name: Setup Node Env
uses: actions/setup-node@v4
with:
node-version: '20'

- name: Install supersetbot from npm
if: ${{ inputs.from-npm == 'true' }}
shell: bash
run: npm install -g supersetbot

- name: "Checkout ${{ github.ref }} ( ${{ github.sha }} )"
if: ${{ inputs.from-npm == 'false' }}
uses: actions/checkout@v4
with:
repository: apache-superset/supersetbot
path: supersetbot

- name: Setup supersetbot from repo
if: ${{ inputs.from-npm == 'false' }}
shell: bash
working-directory: supersetbot
run: |
# simple trick to install globally with dependencies
npm pack
npm install -g ./supersetbot*.tgz
- name: echo supersetbot version
shell: bash
run: supersetbot version
13 changes: 5 additions & 8 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,14 +19,11 @@ updates:
open-pull-requests-limit: 30
versioning-strategy: increase

- package-ecosystem: "pip"
directory: "/requirements/"
schedule:
interval: "monthly"
labels:
- pip
- dependabot
open-pull-requests-limit: 30

# - package-ecosystem: "pip"
# NOTE: as dependabot isn't compatible with our python
# dependency setup (pip-compile-multi), we'll be using
# `supersetbot` instead

- package-ecosystem: "npm"
directory: ".github/actions"
Expand Down
5 changes: 5 additions & 0 deletions .github/labeler.yml
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,11 @@
- any-glob-to-any-file:
- 'superset/translations/zh/**'

"i18n:traditional-chinese":
- changed-files:
- any-glob-to-any-file:
- 'superset/translations/zh_TW/**'

"i18n:dutch":
- changed-files:
- any-glob-to-any-file:
Expand Down
13 changes: 11 additions & 2 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -106,9 +106,18 @@ testCSV.csv
apache-superset-*.tar.gz*
release.json

# Translation binaries
messages.mo
# Translation-related files
# these json files are generated by ./scripts/po2json.sh
superset/translations/**/messages.json
# these mo binary files are generated by `pybabel compile`
superset/translations/**/messages.mo

docker/requirements-local.txt

cache/
docker/*local*

.temp_cache

# Jest test report
test-report.html
45 changes: 21 additions & 24 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -19,24 +19,6 @@ repos:
rev: v0.2.2
hooks:
- id: auto-walrus
- repo: https://github.com/asottile/pyupgrade
rev: v3.4.0
hooks:
- id: pyupgrade
args:
- --py39-plus
- repo: https://github.com/hadialqattan/pycln
rev: v2.1.2
hooks:
- id: pycln
args:
- --disable-all-dunder-policy
- --exclude=superset/config.py
- --extend-exclude=tests/integration_tests/superset_test_config.*.py
- repo: https://github.com/PyCQA/isort
rev: 5.12.0
hooks:
- id: isort
- repo: https://github.com/pre-commit/mirrors-mypy
rev: v1.3.0
hooks:
Expand Down Expand Up @@ -65,18 +47,13 @@ repos:
hooks:
- id: check-docstring-first
- id: check-added-large-files
exclude: \.(geojson)$
exclude: ^.*\.(geojson)$|^docs/static/img/screenshots/.*
- id: check-yaml
exclude: ^helm/superset/templates/
- id: debug-statements
- id: end-of-file-fixer
- id: trailing-whitespace
args: ["--markdown-linebreak-ext=md"]
- repo: https://github.com/psf/black
rev: 23.1.0
hooks:
- id: black
language_version: python3
- repo: https://github.com/pre-commit/mirrors-prettier
rev: v3.1.0 # Use the sha or tag you want to point at
hooks:
Expand All @@ -94,3 +71,23 @@ repos:
hooks:
- id: helm-docs
files: helm
- repo: https://github.com/astral-sh/ruff-pre-commit
rev: v0.4.0
hooks:
- id: ruff
args: [ --fix ]
- id: ruff-format
- repo: local
hooks:
- id: pylint
name: pylint
entry: pylint
language: system
types: [python]
exclude: ^(tests/|superset/migrations/|scripts/|RELEASING/|docker/)
args:
[
"-rn", # Only display messages
"-sn", # Don't display the score
"--rcfile=.pylintrc",
]
5 changes: 3 additions & 2 deletions .pylintrc
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ persistent=yes

# List of plugins (as comma separated values of python modules names) to load,
# usually to register additional checkers.
load-plugins=
load-plugins=superset.extensions.pylint

# Use multiple processes to speed up Pylint.
jobs=2
Expand Down Expand Up @@ -77,6 +77,7 @@ disable=
cyclic-import, # re-enable once this no longer raises false positives
missing-docstring,
duplicate-code,
line-too-long,
unspecified-encoding,
too-many-instance-attributes # re-enable once this no longer raises false positives

Expand Down Expand Up @@ -171,7 +172,7 @@ max-nested-blocks=5
[FORMAT]

# Maximum number of characters on a single line.
max-line-length=90
max-line-length=100

# Regexp for a line that is allowed to be longer than the limit.
ignore-long-lines=^\s*(# )?<?https?://\S+>?$
Expand Down
6 changes: 6 additions & 0 deletions .rat-excludes
Original file line number Diff line number Diff line change
Expand Up @@ -64,5 +64,11 @@ temporary_superset_ui/*
# docs overrides for third party logos we don't have the rights to
google-big-query.svg
google-sheets.svg
ibm-db2.svg
postgresql.svg
snowflake.svg

# docs-related
erd.puml
erd.svg
intro_header.txt
Loading

0 comments on commit 0fc4fe2

Please sign in to comment.