Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
53 changes: 53 additions & 0 deletions .github/workflows/test-python.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,13 +7,17 @@ name: "[tower] Test python"

on:
pull_request:
schedule:
# Detect new stable PyArrow/PyIceberg releases even when no PR is open.
- cron: "17 6 * * *"
Comment on lines +10 to +12

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should this just be a separate workflow? Do we need to run the tests on this interval?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This just runs the tests once a day as well as on every PR.
To me it seems it belongs here. We should run the tests + dependencies compatibility at once? Seems like a reasonable "all things python" coupling.
But If you feel strongly about it, I can move it to another workflow I guess


concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true

jobs:
test:
if: github.event_name == 'pull_request'
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
Expand Down Expand Up @@ -43,3 +47,52 @@ jobs:

- name: Run tests
run: uv run pytest tests

iceberg-compatibility:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
include:
- dependency_set: minimum
pyarrow: "pyarrow==23.0.1"
pyiceberg: "pyiceberg[sql-sqlite]==0.11.1"
- dependency_set: latest
pyarrow: "pyarrow"
pyiceberg: "pyiceberg[sql-sqlite]"

steps:
- uses: actions/checkout@v6

- name: Install the latest version of uv
uses: astral-sh/setup-uv@v6

- name: "Set up Python"
uses: actions/setup-python@v6
with:
python-version-file: ".python-version"

- name: Install the project
run: uv sync --locked --all-extras --dev

- name: Resolve ${{ matrix.dependency_set }} Iceberg dependencies
run: >-
uv pip install
--python .venv/bin/python
--strict
--resolution highest
--upgrade-package pyarrow
--upgrade-package pyiceberg
'${{ matrix.pyarrow }}'
'${{ matrix.pyiceberg }}'

- name: Show resolved dependency versions
run: |
uv run --no-sync python - <<'PY'
from importlib.metadata import version

print(f"PyArrow {version('pyarrow')}; PyIceberg {version('pyiceberg')}")
PY

- name: Run Iceberg compatibility tests
run: uv run --no-sync pytest tests/tower/test_tables.py tests/tower/test_storage.py
Comment thread
konstantinoscs marked this conversation as resolved.
Loading