Bladeren bron

remove debugprint

justheuristic 3 jaren geleden
bovenliggende
commit
6583763ed9
1 gewijzigde bestanden met toevoegingen van 3 en 5 verwijderingen
  1. 3 5
      .github/workflows/run-tests.yaml

+ 3 - 5
.github/workflows/run-tests.yaml

@@ -28,14 +28,12 @@ jobs:
           pip install -r requirements.txt
           pip install -r requirements.txt
       - name: Delete previous model, if exists
       - name: Delete previous model, if exists
         run: |
         run: |
-          echo $(env)
-          exit 255
-          export HF_TAG=$(python -c "import os; print(os.environ.get('GITHUB_REF_NAME') or os.environ.get('GITHUB_BASE_REF') or 'main')")
+          export HF_TAG=$(python -c "import os; print(os.environ.get('GITHUB_HEAD_REF') or os.environ.get('GITHUB_REF_NAME'))")
           python -c "from huggingface_hub import delete_repo; delete_repo(token='$BLOOM_TESTING_WRITE_TOKEN', \
           python -c "from huggingface_hub import delete_repo; delete_repo(token='$BLOOM_TESTING_WRITE_TOKEN', \
           name='test-bloomd-350m-$HF_TAG', organization='bloom-testing')" || true
           name='test-bloomd-350m-$HF_TAG', organization='bloom-testing')" || true
       - name: Convert model and push to hub
       - name: Convert model and push to hub
         run: |
         run: |
-          export HF_TAG=$(python -c "import os; print(os.environ.get('GITHUB_BASE_REF') or os.environ.get('GITHUB_REF_NAME'))")
+          export HF_TAG=$(python -c "import os; print(os.environ.get('GITHUB_HEAD_REF') or os.environ.get('GITHUB_REF_NAME'))")
           python -m cli.convert_model --model bigscience/bloom-350m  --output_path ./converted_model \
           python -m cli.convert_model --model bigscience/bloom-350m  --output_path ./converted_model \
             --output_repo bloom-testing/test-bloomd-350m-$HF_TAG --use_auth_token $BLOOM_TESTING_WRITE_TOKEN
             --output_repo bloom-testing/test-bloomd-350m-$HF_TAG --use_auth_token $BLOOM_TESTING_WRITE_TOKEN
 
 
@@ -66,7 +64,7 @@ jobs:
           pip install -r requirements-dev.txt
           pip install -r requirements-dev.txt
       - name: Test
       - name: Test
         run: |
         run: |
-          export HF_TAG=$(python -c "import os; print(os.environ.get('GITHUB_REF_NAME') or os.environ.get('GITHUB_BASE_REF') or 'main')")
+          export HF_TAG=$(python -c "import os; print(os.environ.get('GITHUB_HEAD_REF') or os.environ.get('GITHUB_REF_NAME'))")
           export MODEL_NAME=bloom-testing/test-bloomd-350m-$HF_TAG
           export MODEL_NAME=bloom-testing/test-bloomd-350m-$HF_TAG
           export REF_NAME=bigscience/bloom-350m
           export REF_NAME=bigscience/bloom-350m