@@ -34,20 +34,51 @@ jobs:
3434 - name : Build wheel and sdist
3535 run : python -m build
3636
37+ - name : Verify wheel contents
38+ run : |
39+ pip install dist/*.whl
40+ python -c "from code_intelligence.detectors.registry import DetectorRegistry; r = DetectorRegistry(); r.load_builtin_detectors(); print(f'Build OK: {len(r.all_detectors())} detectors')"
41+
3742 - name : Upload build artifacts
3843 uses : actions/upload-artifact@v4
3944 with :
4045 name : dist
4146 path : dist/
4247
43- test-install :
44- name : Test install — Python ${{ matrix.python }} / ${{ matrix.os }}
48+ test-os :
49+ name : " ${{ matrix.os }} / Python ${{ matrix.python }}"
4550 needs : build
4651 strategy :
4752 fail-fast : false
4853 matrix :
49- os : [ubuntu-latest, ubuntu-22.04, ubuntu-20.04, macos-latest, windows-latest]
50- python : ["3.11", "3.12", "3.13"]
54+ include :
55+ # Windows 10/11 (latest runner is Windows Server 2022 = Win 11 compatible)
56+ - os : windows-latest
57+ python : " 3.11"
58+ - os : windows-latest
59+ python : " 3.12"
60+ - os : windows-latest
61+ python : " 3.13"
62+ # macOS (Intel + Apple Silicon)
63+ - os : macos-latest
64+ python : " 3.11"
65+ - os : macos-latest
66+ python : " 3.12"
67+ - os : macos-latest
68+ python : " 3.13"
69+ # Ubuntu (covers Debian-based Linux)
70+ - os : ubuntu-latest
71+ python : " 3.11"
72+ - os : ubuntu-latest
73+ python : " 3.12"
74+ - os : ubuntu-latest
75+ python : " 3.13"
76+ - os : ubuntu-22.04
77+ python : " 3.11"
78+ - os : ubuntu-22.04
79+ python : " 3.12"
80+ - os : ubuntu-20.04
81+ python : " 3.11"
5182 runs-on : ${{ matrix.os }}
5283 steps :
5384 - name : Download build artifacts
6596 shell : bash
6697 run : pip install dist/*.whl
6798
68- - name : Verify CLI entry point
99+ - name : Verify CLI
69100 run : code-intelligence --help
70101
71102 - name : Verify detectors load
@@ -75,21 +106,48 @@ jobs:
75106 run : python -c "import importlib.metadata; print(importlib.metadata.version('code-intelligence'))"
76107
77108 test-container :
78- name : Test install — ${{ matrix.container }}
109+ name : " ${{ matrix.name }}"
79110 needs : build
80111 runs-on : ubuntu-latest
81112 strategy :
82113 fail-fast : false
83114 matrix :
84- container :
85- - " registry.access.redhat.com/ubi8/python-311:latest"
86- - " registry.access.redhat.com/ubi9/python-311:latest"
87- - " registry.access.redhat.com/ubi9/python-312:latest"
88- - " python:3.11-slim-bookworm"
89- - " python:3.12-slim-bookworm"
90- - " python:3.13-slim-bookworm"
91- - " python:3.11-alpine"
92- - " python:3.12-alpine"
115+ include :
116+ # RHEL/UBI (Red Hat Enterprise Linux)
117+ - name : " UBI 8 / Python 3.11 (RHEL 8)"
118+ container : " registry.access.redhat.com/ubi8/python-311:latest"
119+ setup : " dnf install -y libxml2-devel libxslt-devel gcc python3-devel 2>/dev/null || true"
120+ - name : " UBI 9 / Python 3.11 (RHEL 9)"
121+ container : " registry.access.redhat.com/ubi9/python-311:latest"
122+ setup : " dnf install -y libxml2-devel libxslt-devel gcc python3-devel 2>/dev/null || true"
123+ - name : " UBI 9 / Python 3.12 (RHEL 9)"
124+ container : " registry.access.redhat.com/ubi9/python-312:latest"
125+ setup : " dnf install -y libxml2-devel libxslt-devel gcc python3-devel 2>/dev/null || true"
126+ # Debian / Ubuntu
127+ - name : " Debian Bookworm / Python 3.11"
128+ container : " python:3.11-slim-bookworm"
129+ setup : " apt-get update && apt-get install -y --no-install-recommends gcc libxml2-dev libxslt1-dev"
130+ - name : " Debian Bookworm / Python 3.12"
131+ container : " python:3.12-slim-bookworm"
132+ setup : " apt-get update && apt-get install -y --no-install-recommends gcc libxml2-dev libxslt1-dev"
133+ - name : " Debian Bookworm / Python 3.13"
134+ container : " python:3.13-slim-bookworm"
135+ setup : " apt-get update && apt-get install -y --no-install-recommends gcc libxml2-dev libxslt1-dev"
136+ # Alpine (musl libc — strictest compatibility test)
137+ - name : " Alpine / Python 3.11"
138+ container : " python:3.11-alpine"
139+ setup : " apk add --no-cache gcc musl-dev libxml2-dev libxslt-dev"
140+ - name : " Alpine / Python 3.12"
141+ container : " python:3.12-alpine"
142+ setup : " apk add --no-cache gcc musl-dev libxml2-dev libxslt-dev"
143+ # Amazon Linux (AWS Lambda / ECS)
144+ - name : " Amazon Linux 2023 / Python 3.11"
145+ container : " amazonlinux:2023"
146+ setup : " dnf install -y python3.11 python3.11-pip python3.11-devel gcc libxml2-devel libxslt-devel"
147+ # Fedora (latest glibc)
148+ - name : " Fedora 40 / Python 3.12"
149+ container : " fedora:40"
150+ setup : " dnf install -y python3 python3-pip python3-devel gcc libxml2-devel libxslt-devel"
93151 container :
94152 image : ${{ matrix.container }}
95153 steps :
@@ -99,27 +157,21 @@ jobs:
99157 name : dist
100158 path : dist/
101159
102- - name : Install system deps (Alpine)
103- if : contains(matrix.container, 'alpine')
104- run : apk add --no-cache gcc musl-dev libxml2-dev libxslt-dev
105-
106- - name : Install system deps (UBI/RHEL)
107- if : contains(matrix.container, 'ubi')
108- run : |
109- dnf install -y libxml2-devel libxslt-devel gcc python3-devel 2>/dev/null || true
160+ - name : Install system deps
161+ run : ${{ matrix.setup }}
110162
111163 - name : Install wheel
112- run : pip install dist/*.whl
164+ run : pip install dist/*.whl || pip3 install dist/*.whl
113165
114166 - name : Verify CLI
115- run : code-intelligence --help
167+ run : code-intelligence --help || python3 -m code_intelligence.cli --help
116168
117169 - name : Verify detectors load
118- run : python -c "from code_intelligence.detectors.registry import DetectorRegistry; r = DetectorRegistry(); r.load_builtin_detectors(); print(f'{len(r.all_detectors())} detectors loaded')"
170+ run : python3 -c "from code_intelligence.detectors.registry import DetectorRegistry; r = DetectorRegistry(); r.load_builtin_detectors(); print(f'{len(r.all_detectors())} detectors loaded')"
119171
120172 publish-pypi :
121173 name : Publish to PyPI
122- needs : [test-install , test-container]
174+ needs : [test-os , test-container]
123175 runs-on : ubuntu-latest
124176 if : inputs.dry_run == false
125177 environment :
0 commit comments