Skip to content

Commit 17ea897

Browse files
committed
Add windows install test
1 parent 58ed4f5 commit 17ea897

2 files changed

Lines changed: 97 additions & 7 deletions

File tree

.github/workflows/pr.yaml

Lines changed: 11 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -47,15 +47,19 @@ jobs:
4747
uses: './.github/workflows/testing-unit.yaml'
4848
secrets: inherit
4949

50-
integration-tests:
51-
uses: './.github/workflows/testing-integration.yaml'
52-
secrets: inherit
53-
needs: unit-tests
50+
# integration-tests:
51+
# uses: './.github/workflows/testing-integration.yaml'
52+
# secrets: inherit
53+
# needs: unit-tests
5454

55-
dependency-tests:
56-
uses: './.github/workflows/testing-dependency.yaml'
55+
# dependency-tests:
56+
# uses: './.github/workflows/testing-dependency.yaml'
57+
# secrets: inherit
58+
# needs: unit-tests
59+
60+
testing-install:
61+
uses: './.github/workflows/testing-install.yaml'
5762
secrets: inherit
58-
needs: unit-tests
5963

6064
package:
6165
name: Check packaging
Lines changed: 86 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,86 @@
1+
name: Installation Tests
2+
3+
on:
4+
workflow_call:
5+
workflow_dispatch:
6+
pull_request:
7+
8+
permissions:
9+
contents: read
10+
pull-requests: write
11+
12+
jobs:
13+
test-install-linux:
14+
runs-on: ubuntu-latest
15+
strategy:
16+
matrix:
17+
python: [3.9, 3.10, 3.11, 3.12, 3.13]
18+
19+
steps:
20+
- name: Checkout code
21+
uses: actions/checkout@v4
22+
23+
- name: Set up Python ${{ matrix.python }}
24+
uses: actions/setup-python@v5
25+
with:
26+
python-version: ${{ matrix.python }}
27+
28+
- name: Install build tools
29+
run: |
30+
python -m pip install --upgrade pip setuptools wheel build
31+
32+
- name: Build sdist & wheel
33+
run: python -m build --sdist --wheel
34+
35+
- name: Install from built artifacts
36+
shell: bash
37+
run: |
38+
pip install dist/*.whl || pip install dist/*.tar.gz
39+
40+
- name: Verify import & version
41+
run: |
42+
python - <<EOF
43+
import pinecone
44+
print("Imported OK, version:", pinecone.__version__)
45+
EOF
46+
47+
test-install-windows:
48+
runs-on: windows-latest
49+
strategy:
50+
matrix:
51+
python: [3.9, 3.10, 3.11, 3.12, 3.13]
52+
steps:
53+
- name: Checkout code
54+
uses: actions/checkout@v4
55+
56+
- name: Set up Python ${{ matrix.python }}
57+
uses: actions/setup-python@v5
58+
with:
59+
python-version: ${{ matrix.python }}
60+
61+
- name: Install build tools
62+
run: |
63+
python -m pip install --upgrade pip setuptools wheel build
64+
65+
- name: Build sdist & wheel
66+
run: python -m build --sdist --wheel
67+
68+
- name: Install from built artifacts
69+
shell: pwsh
70+
run: |
71+
$wheels = Get-ChildItem -Path "dist" -Filter "*.whl"
72+
$sdists = Get-ChildItem -Path "dist" -Filter "*.tar.gz"
73+
if ($wheels) {
74+
pip install $wheels[0].FullName
75+
}
76+
elseif ($sdists) {
77+
pip install $sdists[0].FullName
78+
}
79+
else {
80+
throw "No wheel or sdist found in dist/"
81+
}
82+
83+
- name: Verify import & version
84+
shell: pwsh
85+
run: |
86+
python -c "import pinecone; print('Imported OK, version:', pinecone.__version__)"

0 commit comments

Comments
 (0)