Skip to content

Commit

Permalink
fix
Browse files Browse the repository at this point in the history
  • Loading branch information
ChengjieLi28 committed Oct 29, 2024
1 parent 0705ffc commit 2395133
Showing 1 changed file with 31 additions and 28 deletions.
59 changes: 31 additions & 28 deletions .github/workflows/build-wheel.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,9 @@ jobs:
matrix:
os: [ubuntu-latest, macos-13, windows-latest]
arch: [auto]
# Cannot set like this: ">=3.9,<3.11" here,
# which will result in two packages running within a single runner,
# potentially causing conflicts in the Python environment.
requires-python: [">=3.9,<3.10", ">=3.10,<3.11", ">=3.11,<3.12", ">=3.12,<3.13"]
include:
- os: ubuntu-latest
Expand Down Expand Up @@ -111,31 +114,31 @@ jobs:
with:
path: ./python/dist/*.tar.gz

# upload_pypi:
# needs: [build_wheels, build_sdist]
# runs-on: ubuntu-latest
# # upload to PyPI on every tag starting with 'v'
# if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags/v')
# steps:
# - uses: actions/download-artifact@v3
# with:
# # unpacks default artifact into dist/
# # if `name: artifact` is omitted, the action will create extra parent dir
# name: artifact
# path: dist
#
# # if is xprobe repo, upload to pypi
# - uses: pypa/[email protected]
# if: github.repository == 'xorbitsai/xoscar'
# with:
# user: __token__
# password: ${{ secrets.PYPI_PASSWORD }}
#
# # if is not xprobe repo, upload to test
# - uses: pypa/[email protected]
# if: github.repository != 'xorbitsai/xoscar'
# with:
# user: __token__
# password: ${{ secrets.TEST_PYPI_PASSWORD }}
# verbose: true
# repository_url: https://test.pypi.org/legacy/
upload_pypi:
needs: [build_wheels, build_sdist]
runs-on: ubuntu-latest
# upload to PyPI on every tag starting with 'v'
if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags/v')
steps:
- uses: actions/download-artifact@v3
with:
# unpacks default artifact into dist/
# if `name: artifact` is omitted, the action will create extra parent dir
name: artifact
path: dist

# if is xprobe repo, upload to pypi
- uses: pypa/[email protected]
if: github.repository == 'xorbitsai/xoscar'
with:
user: __token__
password: ${{ secrets.PYPI_PASSWORD }}

# if is not xprobe repo, upload to test
- uses: pypa/[email protected]
if: github.repository != 'xorbitsai/xoscar'
with:
user: __token__
password: ${{ secrets.TEST_PYPI_PASSWORD }}
verbose: true
repository_url: https://test.pypi.org/legacy/

0 comments on commit 2395133

Please sign in to comment.