Skip to content

Commit

Permalink
Temporary disable pypi upload
Browse files Browse the repository at this point in the history
  • Loading branch information
Guillemdb committed Aug 30, 2024
1 parent d208f5b commit c0ab46d
Show file tree
Hide file tree
Showing 3 changed files with 51 additions and 48 deletions.
93 changes: 47 additions & 46 deletions .github/workflows/push.yml
Original file line number Diff line number Diff line change
Expand Up @@ -139,6 +139,7 @@ jobs:
set -x
rye install bump2version
rye install twine
rye install uv
- name: Create unique version for test.pypi
run: |
Expand All @@ -154,32 +155,32 @@ jobs:
rye build --clean
twine check dist/*
- name: Publish package to TestPyPI
env:
TEST_PYPI_PASS: ${{ secrets.TEST_PYPI_PASS }}
if: "'$TEST_PYPI_PASS' != ''"
uses: pypa/gh-action-pypi-publish@release/v1
with:
password: ${{ secrets.TEST_PYPI_PASS }}
repository-url: https://test.pypi.org/legacy/
skip-existing: true
# - name: Publish package to TestPyPI
# env:
# TEST_PYPI_PASS: ${{ secrets.TEST_PYPI_PASS }}
# if: "'$TEST_PYPI_PASS' != ''"
# uses: pypa/gh-action-pypi-publish@release/v1
# with:
# password: ${{ secrets.TEST_PYPI_PASS }}
# repository-url: https://test.pypi.org/legacy/
# skip-existing: true

- name: Install dependencies
run: |
set -x
sudo apt-get install -y xvfb python-opengl ffmpeg
sudo apt-get install -y xvfb
sudo MUJOCO_PATH=/home/runner/.mujoco/ make install-envs
rye lock
pip install uv
ROM_PASSWORD=${{ secrets.ROM_PASSWORD }} make import-roms
rye lock --all-features
uv pip install --no-cache --system -r requirements.lock
uv pip install dist/*.whl
uv pip install --system dist/*.whl
ROM_PASSWORD=${{ secrets.ROM_PASSWORD }} make import-roms
- name: Test package
run: |
set -x
rm -rf $PROJECT_DIR
xvfb-run -s "-screen 0 1400x900x24" rye run test
make test
bump-version:
name: Bump package version
Expand Down Expand Up @@ -214,34 +215,34 @@ jobs:
login: "${{ env.bot_name }}"
token: "${{ secrets.BOT_AUTH_TOKEN }}"

release-package:
name: Release PyPI package
env:
PYPI_PASS: ${{ secrets.PYPI_PASS }}
if: "contains(github.event.head_commit.message, 'Bump version') && github.ref == 'refs/heads/master' && '$PYPI_PASS' != ''"
runs-on: ubuntu-20.04
steps:
- name: actions/checkout
uses: actions/checkout@v3
- name: Set up Python 3.8
uses: actions/setup-python@v3
with:
python-version: 3.8
- name: Install dependencies
run: |
set -x
python -m pip install -U pip
python -m pip install -U setuptools twine wheel
- name: Build package
run: |
set -x
python setup.py --version
python setup.py bdist_wheel sdist --format=gztar
twine check dist/*
- name: Publish package to PyPI
uses: pypa/gh-action-pypi-publish@master
with:
user: __token__
password: ${{ secrets.PYPI_PASS }}
# release-package:
# name: Release PyPI package
# env:
# PYPI_PASS: ${{ secrets.PYPI_PASS }}
# if: "contains(github.event.head_commit.message, 'Bump version') && github.ref == 'refs/heads/master' && '$PYPI_PASS' != ''"
# runs-on: ubuntu-20.04
# steps:
# - name: actions/checkout
# uses: actions/checkout@v3
# - name: Set up Python 3.8
# uses: actions/setup-python@v3
# with:
# python-version: 3.8
# - name: Install dependencies
# run: |
# set -x
# python -m pip install -U pip
# python -m pip install -U setuptools twine wheel
#
# - name: Build package
# run: |
# set -x
# python setup.py --version
# python setup.py bdist_wheel sdist --format=gztar
# twine check dist/*
#
# - name: Publish package to PyPI
# uses: pypa/gh-action-pypi-publish@master
# with:
# user: __token__
# password: ${{ secrets.PYPI_PASS }}
4 changes: 3 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,9 @@ doctest:

.PHONY: test
test:
xvfb-run -s "-screen 0 1400x900x24" make test-parallel test-ray
find . -name "*.pyc" -delete
PYVIRTUALDISPLAY_DISPLAYFD=0 SKIP_CLASSIC_CONTROL=1 xvfb-run -s "-screen 0 1400x900x24" pytest -n auto -s -o log_cli=true -o log_cli_level=info tests
PYVIRTUALDISPLAY_DISPLAYFD=0 xvfb-run -s "-screen 0 1400x900x24" pytest -s -o log_cli=true -o log_cli_level=info tests/control/test_classic_control.py

.PHONY: run-codecov-test
run-codecov-test:
Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ nes = [
]
classic-control = ["gymnasium[classic_control]>=0.29.1, == 0.*", "pygame>=2.6.0"]
ray = ["ray>=2.35.0"]
dm_control = ["dm-control>=1.0.22"]#, "gym @ git+https://github.com/FragileTech/gym.git"]
dm_control = ["dm-control>=1.0.22", "gym @ git+https://github.com/FragileTech/gym.git"]
retro = ["stable_retro"]
jupyter = ["jupyterlab>=3.2.0"]
box_2d = ["box2d-py==2.3.5"]
Expand Down

0 comments on commit c0ab46d

Please sign in to comment.