Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

build wheel #2 #8

Merged
merged 1 commit into from
May 28, 2022
Merged
Show file tree
Hide file tree
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
16 changes: 12 additions & 4 deletions .github/workflows/cicd.yaml
Original file line number Diff line number Diff line change
@@ -1,14 +1,22 @@
name: ci-cd-pipeline

# TODO: Once this works, run automatically every night to check compatibility with most recent toolchain

on: [push]
on:
push:
schedule:
- cron: "0 1 * * 4"
jobs:
setup:
ci-cd:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Build
run: docker-compose build
- name: Test
run: docker-compose run test
- name: Extract wheel
run: docker run --rm --entrypoint cat pyapsi:dev /tmp/pyapsi/dist/apsi-0.1.0-cp39-cp39-linux_x86_64.whl > apsi-0.1.0-cp39-cp39-linux_x86_64.whl
- name: Archive wheel
uses: actions/upload-artifact@v3
with:
name: apsi-0.1.0-cp39-cp39-linux_x86_64.whl
path: apsi-0.1.0-cp39-cp39-linux_x86_64.whl
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -3,3 +3,4 @@ build
*.bin
.venv/
__pycache__/
*.whl
6 changes: 4 additions & 2 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,9 @@ RUN git clone https://github.com/microsoft/apsi /tmp/pyapsi/external/apsi
RUN sed -i "s/-D_AVX2_/-D_AVX_/g" /tmp/pyapsi/external/apsi/CMakeLists.txt
RUN sed -i "s/_AVX2.S/.S/g" /tmp/pyapsi/external/apsi/common/apsi/fourq/amd64/CMakeLists.txt

RUN poetry install && \
poetry run pip install --verbose .
RUN poetry install
RUN poetry run pip install --verbose .

RUN poetry run python setup.py bdist_wheel

CMD ["poetry", "run", "pytest", "tests"]
36 changes: 18 additions & 18 deletions poetry.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ description = "Python wrapper for APSI"
authors = ["Lukas Grossberger <[email protected]>"]

[tool.poetry.dependencies]
python = "^3.8"
python = ">=3.9,<3.10"
pyzmq = "^22.3.0"
pybind11 = "^2.9.2"

Expand Down
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -174,5 +174,5 @@ def build_extension(self, ext):
cmdclass={"build_ext": CMakeBuild},
extras_require={"test": "pytest"},
zip_safe=False,
python_requires=">=3.8",
python_requires=">=3.9,<3.10",
)