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

Update python-publish.yml #118

Merged
merged 20 commits into from
Mar 12, 2025
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
31 changes: 24 additions & 7 deletions .github/workflows/python-publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,20 +18,37 @@ jobs:
python-version: '3.x'
- name: Install dependencies
run: |
python -m pip install --upgrade pip
python -m pip install --upgrade pip build
pip install setuptools wheel numpy
- name: Build the package
run: pip install .
run: |
pip install .
python -m build
- name: Build wheel with cibuildwheel
run: |
pip install cibuildwheel
cibuildwheel --platform linux
env:
#it is not working with python 3.6, which is outdated and no longer supported by many modern packages, including scikit-build-core.
CIBW_SKIP: "cp36-*"
CIBW_BUILD: "cp38-* cp39-* cp310-* cp311-* cp312-*"

#- name: Publish distribution 📦 to Test PyPI
# run: |
# twine upload --repository testpypi wheelhouse/* --verbose
# env:
# TWINE_USERNAME: __token__
# TWINE_PASSWORD: ${{ secrets.TEST_PYPI_PASSWORD }}

- name: Publish distribution 📦 to Test PyPI
if: startsWith(github.ref, 'refs/tags')
uses: pypa/gh-action-pypi-publish@master
uses: pypa/gh-action-pypi-publish@release/v1
with:
username: __token__
password: ${{ secrets.TEST_PYPI_PASSWORD }}
repository_url: https://test.pypi.org/legacy/
repository-url: https://test.pypi.org/legacy/

- name: Publish distribution 📦 to PyPI
if: startsWith(github.ref, 'refs/tags')
uses: pypa/gh-action-pypi-publish@master
uses: pypa/gh-action-pypi-publish@release/v1
with:
username: __token__
password: ${{ secrets.PYPI_PASSWORD }}
2 changes: 1 addition & 1 deletion README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ Several ADAS formats can currently be managed -- please see the docs. Please con


Surface data
-----------
------------

Aurora also contains an interface to read and plot plasma-material interaction data, for the most fusion-relevant ion species and wall materials, namely concerning reflection, sputtering and implantation of plasma ions from/into wall materials. The data were generated with the TRIM.SP Monte Carlo program.

Expand Down
6 changes: 4 additions & 2 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
name = "aurorafusion"
dynamic = ["version"]
description = "Aurora package for particle transport, radiation and neutrals in magnetically-confined plasmas"
readme = {file = "README.rst", content-type = "text/x-rst"} # Explicitly set long_description
authors = [
{ name = "F. Sciortino", email = "[email protected]" },
]
Expand Down Expand Up @@ -34,15 +35,16 @@ dependencies = [
# been removed/renamed by a commit from October 2022.
# This constrains xarray<=v2022.09.0
"xarray==v2022.09.0",
"tqdm", #only because it is missing in OMFIT dependencies!
"tqdm", # only because it is missing in OMFIT dependencies!
# omfit_classes has issues with newer versions of
# matplotlib, see https://github.com/gafusion/OMFIT-source/issues/6784
# (link appears to be broken - MT 2024-09-26; trying to relax <=3.5)
"matplotlib",
]

[build-system]
requires = ["scikit-build-core", "numpy"]
# scikit-build-core is used to integrate with CMake
requires = ["scikit-build-core", "numpy", "setuptools"]
build-backend = "scikit_build_core.build"

[tool.scikit-build]
Expand Down