Skip to content

Commit 5a4c12c

Browse files
committed
CI: Separate GHA workflow definition for Kinesis
1 parent c3aaad2 commit 5a4c12c

File tree

2 files changed

+101
-71
lines changed

2 files changed

+101
-71
lines changed

.github/workflows/kinesis.yml

Lines changed: 101 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,101 @@
1+
---
2+
name: "Tests: Kinesis"
3+
4+
on:
5+
pull_request:
6+
paths:
7+
- '.github/workflows/kinesis.yml'
8+
- 'cratedb_toolkit/io/kinesis/**'
9+
- 'tests/io/kinesis/**'
10+
- 'pyproject.toml'
11+
push:
12+
branches: [ main ]
13+
paths:
14+
- '.github/workflows/kinesis.yml'
15+
- 'cratedb_toolkit/io/kinesis/**'
16+
- 'tests/io/kinesis/**'
17+
- 'pyproject.toml'
18+
19+
# Allow job to be triggered manually.
20+
workflow_dispatch:
21+
22+
# Run the job each night after CrateDB nightly has been published.
23+
schedule:
24+
- cron: '0 3 * * *'
25+
26+
# Cancel in-progress jobs when pushing to the same branch.
27+
concurrency:
28+
cancel-in-progress: true
29+
group: ${{ github.workflow }}-${{ github.ref }}
30+
31+
jobs:
32+
33+
tests:
34+
35+
runs-on: ${{ matrix.os }}
36+
strategy:
37+
fail-fast: false
38+
matrix:
39+
os: ["ubuntu-latest"]
40+
python-version: [
41+
"3.11",
42+
"3.13",
43+
]
44+
45+
env:
46+
OS: ${{ matrix.os }}
47+
PYTHON: ${{ matrix.python-version }}
48+
UV_SYSTEM_PYTHON: true
49+
# Do not tear down Testcontainers
50+
TC_KEEPALIVE: true
51+
52+
# https://docs.github.com/en/actions/using-containerized-services/about-service-containers
53+
services:
54+
cratedb:
55+
image: crate/crate:nightly
56+
ports:
57+
- 4200:4200
58+
- 5432:5432
59+
60+
name: "
61+
Kinesis:
62+
Python ${{ matrix.python-version }} on OS ${{ matrix.os }}"
63+
steps:
64+
65+
- name: Acquire sources
66+
uses: actions/checkout@v4
67+
68+
- name: Install Python
69+
uses: actions/setup-python@v5
70+
with:
71+
python-version: ${{ matrix.python-version }}
72+
73+
- name: Install uv
74+
uses: astral-sh/setup-uv@v6
75+
with:
76+
cache-dependency-glob: |
77+
pyproject.toml
78+
cache-suffix: ${{ matrix.python-version }}
79+
enable-cache: true
80+
version: "latest"
81+
82+
- name: Set up project
83+
run: |
84+
85+
# Install package in editable mode.
86+
uv pip install --editable=.[kinesis,test,develop]
87+
88+
- name: Run linter and software tests
89+
run: |
90+
pytest -m kinesis
91+
92+
- name: Upload coverage to Codecov
93+
uses: codecov/codecov-action@v5
94+
env:
95+
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
96+
with:
97+
files: ./coverage.xml
98+
flags: kinesis
99+
env_vars: OS,PYTHON
100+
name: codecov-umbrella
101+
fail_ci_if_error: true

.github/workflows/main.yml

Lines changed: 0 additions & 71 deletions
Original file line numberDiff line numberDiff line change
@@ -312,74 +312,3 @@ jobs:
312312
env_vars: OS,PYTHON
313313
name: codecov-umbrella
314314
fail_ci_if_error: true
315-
316-
317-
tests-kinesis:
318-
319-
runs-on: ${{ matrix.os }}
320-
strategy:
321-
fail-fast: false
322-
matrix:
323-
os: ["ubuntu-latest"]
324-
python-version: [
325-
"3.11",
326-
"3.13",
327-
]
328-
329-
env:
330-
OS: ${{ matrix.os }}
331-
PYTHON: ${{ matrix.python-version }}
332-
UV_SYSTEM_PYTHON: true
333-
# Do not tear down Testcontainers
334-
TC_KEEPALIVE: true
335-
336-
# https://docs.github.com/en/actions/using-containerized-services/about-service-containers
337-
services:
338-
cratedb:
339-
image: crate/crate:nightly
340-
ports:
341-
- 4200:4200
342-
- 5432:5432
343-
344-
name: "
345-
Kinesis:
346-
Python ${{ matrix.python-version }} on OS ${{ matrix.os }}"
347-
steps:
348-
349-
- name: Acquire sources
350-
uses: actions/checkout@v4
351-
352-
- name: Install Python
353-
uses: actions/setup-python@v5
354-
with:
355-
python-version: ${{ matrix.python-version }}
356-
357-
- name: Install uv
358-
uses: astral-sh/setup-uv@v6
359-
with:
360-
cache-dependency-glob: |
361-
pyproject.toml
362-
cache-suffix: ${{ matrix.python-version }}
363-
enable-cache: true
364-
version: "latest"
365-
366-
- name: Set up project
367-
run: |
368-
369-
# Install package in editable mode.
370-
uv pip install --editable=.[kinesis,test,develop]
371-
372-
- name: Run linter and software tests
373-
run: |
374-
pytest -m kinesis
375-
376-
- name: Upload coverage to Codecov
377-
uses: codecov/codecov-action@v5
378-
env:
379-
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
380-
with:
381-
files: ./coverage.xml
382-
flags: kinesis
383-
env_vars: OS,PYTHON
384-
name: codecov-umbrella
385-
fail_ci_if_error: true

0 commit comments

Comments
 (0)