This is an automated email from the ASF dual-hosted git repository.

xqhu pushed a commit to branch liferoad-no-space-ml
in repository https://gitbox.apache.org/repos/asf/beam.git

commit 17bd4875afdcbbf3485fe3eb425b12d615b51481
Author: liferoad <[email protected]>
AuthorDate: Thu Oct 16 14:27:46 2025 -0400

    Update beam_PreCommit_Python_ML.yml
    
    clean up disk space
---
 .github/workflows/beam_PreCommit_Python_ML.yml | 28 ++++++++++++++++++++++++++
 1 file changed, 28 insertions(+)

diff --git a/.github/workflows/beam_PreCommit_Python_ML.yml 
b/.github/workflows/beam_PreCommit_Python_ML.yml
index e78a5241636..a257299bde0 100644
--- a/.github/workflows/beam_PreCommit_Python_ML.yml
+++ b/.github/workflows/beam_PreCommit_Python_ML.yml
@@ -90,6 +90,18 @@ jobs:
       startsWith(github.event.comment.body, 'Run Python_ML PreCommit')
     steps:
       - uses: actions/checkout@v4
+      - name: Free Disk Space (Ubuntu)
+        if: contains(matrix.os, 'ubuntu-latest')
+        uses: jlumbroso/[email protected]
+        with:
+          # Remove unnecessary packages to free up space
+          tool-cache: false
+          android: true
+          dotnet: true
+          haskell: true
+          large-packages: true
+          docker-images: true
+          swap-storage: true
       - name: Setup repository
         uses: ./.github/actions/setup-action
         with:
@@ -133,3 +145,19 @@ jobs:
           files: '**/pytest*.xml'
           large_files: true
           check_name: "Python ${{ matrix.python_version }} Test Results (${{ 
join(matrix.os, ', ') }})"
+      - name: Cleanup
+        if: always()
+        run: |
+          # Kill any remaining processes
+          sudo pkill -f "gradle" || true
+          sudo pkill -f "java" || true
+          sudo pkill -f "python.*pytest" || true
+          # Clean up temp files and caches
+          sudo rm -rf /tmp/beam-* || true
+          sudo rm -rf /tmp/gradle-* || true
+          sudo rm -rf ~/.cache/pip || true
+          # Clean up ML model caches
+          sudo rm -rf /tmp/transformers_cache || true
+          sudo rm -rf /tmp/torch_cache || true
+          sudo rm -rf ~/.cache/torch || true
+          sudo rm -rf ~/.cache/huggingface || true

Reply via email to