-
Notifications
You must be signed in to change notification settings - Fork 487
156 lines (132 loc) · 4.55 KB
/
install-test.yml
File metadata and controls
156 lines (132 loc) · 4.55 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
name: Test Package Installation
on:
pull_request:
branches: [main]
paths:
- 'pyproject.toml'
- 'uv.lock'
- 'areal/**'
- '.github/workflows/install-test.yml'
push:
branches: [main]
paths:
- 'pyproject.toml'
- 'uv.lock'
- 'areal/**'
- '.github/workflows/install-test.yml'
workflow_dispatch:
concurrency:
group: install-test-${{ github.ref }}
cancel-in-progress: true
jobs:
install-test:
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest, macos-latest]
python-version: ['3.12']
runs-on: ${{ matrix.os }}
name: Install test (${{ matrix.os }}, Python ${{ matrix.python-version }})
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Install uv
uses: astral-sh/setup-uv@v5
with:
enable-cache: true
cache-dependency-glob: 'uv.lock'
- name: Set up Python
run: uv python install ${{ matrix.python-version }}
- name: Install package (basic)
run: uv sync
- name: Verify package import
run: |
uv run python -c "import areal; print(f'areal version: {areal.__version__}')"
- name: Verify core modules are importable
run: |
uv run python -c "
from areal import (
TrainController,
RolloutController,
WorkflowExecutor,
StalenessManager,
workflow_context,
current_platform,
)
print('All core modules imported successfully')
"
- name: Build wheel
run: uv build --wheel
- name: Verify wheel artifact
run: |
ls -la dist/
python -m zipfile -l dist/*.whl | head -20
install-test-cuda-extras:
# Test CUDA extras installation on Linux only (CUDA packages have Linux-only wheels)
# Note: flash-attn is excluded because it requires CUDA compilation infrastructure
# which is not available on standard GitHub runners
runs-on: ubuntu-latest
name: Install test (Linux, CUDA extras)
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Install uv
uses: astral-sh/setup-uv@v5
with:
enable-cache: true
cache-dependency-glob: 'uv.lock'
- name: Set up Python
run: uv python install 3.12
- name: Install package with CUDA extras (excluding flash-attn)
# flash-attn requires CUDA toolkit for compilation, skip it in CI
# Test individual extras that have pre-built wheels
run: uv sync --extra vllm --extra sglang --extra megatron --extra tms
- name: Verify package import with CUDA extras
run: |
uv run python -c "import areal; print(f'areal version: {areal.__version__}')"
- name: Verify CUDA-dependent packages are installed
run: |
uv run python -c "
import importlib.util
packages = ['vllm', 'sglang', 'megatron.core']
for pkg in packages:
spec = importlib.util.find_spec(pkg)
status = 'installed' if spec else 'not found'
print(f'{pkg}: {status}')
"
install-test-docker:
# Test editable installation in Docker runtime image
# This mirrors the installation method documented for Docker users
# Only runs on manual dispatch due to large image pull time
# and `no space on device left` errors on busy runners
if: github.event_name == 'workflow_dispatch'
runs-on: ubuntu-latest
name: Install test (Docker runtime image)
container:
image: ghcr.io/inclusionai/areal-runtime:v0.5.3
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Install package (editable, no deps)
# This is the documented Docker installation method
# Dependencies are pre-installed in the runtime image
run: uv pip install -e . --no-deps
- name: Verify package import
run: |
python -c "import areal; print(f'areal version: {areal.__version__}')"
- name: Verify core modules are importable
run: |
python -c "
from areal import (
TrainController,
RolloutController,
WorkflowExecutor,
StalenessManager,
workflow_context,
current_platform,
)
print('All core modules imported successfully')
"
- name: Run Docker installation validation
run: |
python areal/tools/validate_docker_installation.py