diff --git a/.github/actions/pip-wheels/action.yml b/.github/actions/pip-wheels/action.yml deleted file mode 100644 index 19f2e7bf5e182..0000000000000 --- a/.github/actions/pip-wheels/action.yml +++ /dev/null @@ -1,82 +0,0 @@ -name: Dump local wheels -description: scan local env and dump needed wheels - -inputs: - torch-url: - description: path to the PyTorch downloads - required: false - default: "https://download.pytorch.org/whl/cpu/torch_stable.html" - wheel-dir: - description: local path for export wheels - required: false - default: "_pip-wheels/" - cache-key: - description: update this cache - required: false - default: "pypi_wheels" - -runs: - using: "composite" - steps: - - name: install dev. env - run: pip install -r requirements/ci.txt - shell: bash - - - name: Freeze local emv. - run: | - pip freeze > requirements.dump - cat requirements.dump - shell: bash - - - name: Filter self pkg - run: | - import os - fp = 'requirements.dump' - with open(fp) as fopen: - lines = [ln.strip() for ln in fopen.readlines()] - # prevent collisions with version appendix - lines = [ln.split('+')[0] for ln in lines if '-e ' not in ln] - # drop sphinx theme package - lines = [ln for ln in lines if 'sphinx-theme' not in ln] - with open(fp, 'w') as fopen: - fopen.writelines([ln + os.linesep for ln in lines]) - shell: python - - - name: Dump wheels - run: | - # cat requirements.dump - pip wheel -r requirements.dump --prefer-binary \ - --wheel-dir=".wheels" \ - --extra-index-url=${{ inputs.torch-url }} -f ${{ inputs.wheel-dir }} - ls -lh .wheels/ - shell: bash - - - name: Find diff - id: wheels-diff - run: | - import os, glob - wheels = [os.path.basename(p) for p in glob.glob(".wheels/*")] - pkgs = [os.path.basename(p) for p in glob.glob("${{ inputs.wheel-dir }}/*")] - diff = [w for w in wheels if w not in pkgs] - print(diff) - with open(os.environ['GITHUB_OUTPUT'], 'a') as fh: - print(f'count-new={len(diff)}', file=fh) - shell: python - - - name: Cache pull - if: ${{ steps.wheels-diff.outputs.count-new != 0 }} - uses: actions/cache/restore@v3 - with: - path: ${{ inputs.wheel-dir }} - key: ${{ inputs.cache-key }} - - - run: cp .wheels/* ${{ inputs.wheel-dir }} - if: ${{ steps.wheels-diff.outputs.count-new != 0 }} - shell: bash - - - name: Cache push - if: ${{ steps.wheels-diff.outputs.count-new != 0 }} - uses: actions/cache/save@v3 - with: - path: ${{ inputs.wheel-dir }} - key: ${{ inputs.cache-key }} diff --git a/.github/workflows/ci-tests-fabric.yml b/.github/workflows/ci-tests-fabric.yml index 882fea6c965c6..33f1dac7b27c9 100644 --- a/.github/workflows/ci-tests-fabric.yml +++ b/.github/workflows/ci-tests-fabric.yml @@ -134,15 +134,6 @@ jobs: --find-links="${TORCH_URL}" uv pip list - - name: Dump handy wheels - if: github.event_name == 'push' && github.ref == 'refs/heads/master' - continue-on-error: true - uses: ./.github/actions/pip-wheels - with: - wheel-dir: ${{ env.PYPI_CACHE_DIR }} - torch-url: ${{ env.TORCH_URL }} - cache-key: "pypi_wheels" - - name: Adjust tests if: ${{ matrix.config.pkg-name != 'lightning' }} run: | diff --git a/.github/workflows/ci-tests-pytorch.yml b/.github/workflows/ci-tests-pytorch.yml index 168a6783514c3..cd445022f9df2 100644 --- a/.github/workflows/ci-tests-pytorch.yml +++ b/.github/workflows/ci-tests-pytorch.yml @@ -147,15 +147,6 @@ jobs: if: ${{ matrix.config.pkg-name == 'lightning' }} run: uv pip uninstall pytorch-lightning - - name: Dump handy wheels - if: github.event_name == 'push' && github.ref == 'refs/heads/master' - continue-on-error: true - uses: ./.github/actions/pip-wheels - with: - wheel-dir: ${{ env.PYPI_CACHE_DIR }} - torch-url: ${{ env.TORCH_URL }} - cache-key: "pypi_wheels" - - name: Cache datasets uses: actions/cache@v4 with: diff --git a/.github/workflows/docs-build.yml b/.github/workflows/docs-build.yml index 23ab8417a1c68..79545063905df 100644 --- a/.github/workflows/docs-build.yml +++ b/.github/workflows/docs-build.yml @@ -47,7 +47,6 @@ defaults: env: FREEZE_REQUIREMENTS: "1" TORCH_URL: "https://download.pytorch.org/whl/cpu/" - PYPI_CACHE_DIR: "_pip-wheels" PYPI_LOCAL_DIR: "pypi_pkgs/" jobs: @@ -95,12 +94,6 @@ jobs: aws s3 sync --no-sign-request s3://sphinx-packages/ ${PYPI_LOCAL_DIR} uv pip install lai-sphinx-theme -U -f ${PYPI_LOCAL_DIR} - - name: pip wheels cache - uses: actions/cache/restore@v4 - with: - path: ${{ env.PYPI_CACHE_DIR }} - key: pypi_wheels - - name: Install pandoc & texlive if: ${{ matrix.pkg-name == 'pytorch' }} timeout-minutes: 5 @@ -111,10 +104,8 @@ jobs: - name: Install package & dependencies timeout-minutes: 20 run: | - mkdir -p ${PYPI_CACHE_DIR} # in case cache was not hit - ls -lh ${PYPI_CACHE_DIR} uv pip install .[all] -U -r requirements/${{ matrix.pkg-name }}/docs.txt \ - -f ${PYPI_LOCAL_DIR} -f ${PYPI_CACHE_DIR} --extra-index-url="${TORCH_URL}" + -f ${PYPI_LOCAL_DIR} --extra-index-url="${TORCH_URL}" uv pip list - name: Install req. for Notebooks/tutorials @@ -149,15 +140,6 @@ jobs: retention-days: ${{ env.ARTIFACT_DAYS }} include-hidden-files: true - #- name: Dump handy wheels - # if: github.event_name == 'push' && github.ref == 'refs/heads/master' - # continue-on-error: true - # uses: ./.github/actions/pip-wheels - # with: - # wheel-dir: ${{ env.PYPI_CACHE_DIR }} - # torch-url: ${{ env.TORCH_URL }} - # cache-key: "pypi_wheels" - deploy-docs: needs: docs-make if: github.repository_owner == 'Lightning-AI' && github.event_name != 'pull_request'