From 29addcc7cdf1d0d1f3bb980c3595a8c905f5ad84 Mon Sep 17 00:00:00 2001 From: hychang Date: Tue, 11 Aug 2026 23:23:38 +0800 Subject: [PATCH] Add Superset integration CI job Run a dedicated Superset integration job in GitHub Actions so changes to python-datastore-sqlalchemy are validated against Apache Superset's Datastore DB engine spec tests. The job checks out apache/superset master, uses Python 3.11 to match current Superset support, installs Superset development dependencies with uv, installs this package from the workflow checkout, initializes the Superset test database, and runs tests/integration_tests/db_engine_specs/datastore_tests.py. Install libldap2-dev, libsasl2-dev, and libssl-dev because Superset development dependencies include native packages such as python-ldap that require system headers on GitHub's Ubuntu runners. Keep the Superset validation targeted instead of running the full Superset suite on every package PR. The full upstream suite is broad and can fail for unrelated frontend, service, or environment issues; targeted Datastore engine tests provide the relevant blocking signal for this package. --- .github/workflows/python-ci.yaml | 53 ++++++++++++++++++++++++++++++++ 1 file changed, 53 insertions(+) diff --git a/.github/workflows/python-ci.yaml b/.github/workflows/python-ci.yaml index 0dfce66..059eda4 100644 --- a/.github/workflows/python-ci.yaml +++ b/.github/workflows/python-ci.yaml @@ -53,3 +53,56 @@ jobs: - name: Run tests run: uv run pytest + + superset-integration: + runs-on: ubuntu-latest + + env: + SUPERSET_CONFIG: tests.integration_tests.superset_test_config + SUPERSET_TESTENV: "true" + + steps: + - name: Checkout package + uses: actions/checkout@v4 + with: + path: python-datastore-sqlalchemy + + - name: Checkout Superset + uses: actions/checkout@v4 + with: + repository: apache/superset + ref: master + path: superset + + - name: Set up Python + uses: actions/setup-python@v5 + with: + python-version: '3.11' + + - name: Install uv + uses: astral-sh/setup-uv@v6 + with: + enable-cache: true + + - name: Install Superset system dependencies + run: | + sudo apt-get update + sudo apt-get install -y libldap2-dev libsasl2-dev libssl-dev + + - name: Install Superset dependencies + working-directory: superset + run: | + uv venv .venv --python 3.11 + uv pip install -r requirements/development.txt + uv pip install -e ../python-datastore-sqlalchemy + + - name: Initialize Superset test database + working-directory: superset + run: | + .venv/bin/superset db upgrade + .venv/bin/superset init + .venv/bin/superset load-test-users + + - name: Run Superset datastore integration tests + working-directory: superset + run: .venv/bin/pytest -vv tests/integration_tests/db_engine_specs/datastore_tests.py