Skip to content

Commit

Permalink
Refactor code for speed and clarity
Browse files Browse the repository at this point in the history
  • Loading branch information
UltralyticsAssistant committed Nov 21, 2024
1 parent 8eb920e commit 8be8012
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 14 deletions.
14 changes: 7 additions & 7 deletions .github/workflows/format.yml
Original file line number Diff line number Diff line change
Expand Up @@ -37,10 +37,10 @@ jobs:
uses: ultralytics/actions/cla@cla-branch
with:
github-token: ${{ secrets._GITHUB_TOKEN }}
cla_repository: 'ultralytics/cla'
cla_branch: 'main'
cla_signatures_path: 'signatures/version1/cla.json'
cla_document_url: 'https://docs.ultralytics.com/help/CLA'
allowlist: 'dependabot[bot],github-actions,bot*'
sign_comment: 'I have read the CLA Document and I sign the CLA'
allsigned_comment: 'All Contributors have signed the CLA. ✅'
cla_repository: "ultralytics/cla"
cla_branch: "main"
cla_signatures_path: "signatures/version1/cla.json"
cla_document_url: "https://docs.ultralytics.com/help/CLA"
allowlist: "dependabot[bot],github-actions,bot*"
sign_comment: "I have read the CLA Document and I sign the CLA"
allsigned_comment: "All Contributors have signed the CLA. ✅"
14 changes: 7 additions & 7 deletions .github/workflows/test-retry.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,11 @@ on:
workflow_dispatch:
inputs:
should_fail:
description: 'Force failure to test retry'
description: "Force failure to test retry"
type: boolean
default: false
timeout_test:
description: 'Test timeout handling'
description: "Test timeout handling"
type: boolean
default: false

Expand All @@ -23,7 +23,7 @@ jobs:
echo "This should succeed on first try"
date
echo "Current directory: $PWD"
- name: Test with environment variables
uses: ultralytics/actions/retry@glenn-jocher-patch-1
env:
Expand All @@ -32,7 +32,7 @@ jobs:
run: |
echo "Testing env vars: $TEST_VAR"
echo "GitHub workspace: $GITHUB_WORKSPACE"
- name: Test with working directory
uses: ultralytics/actions/retry@glenn-jocher-patch-1
with:
Expand Down Expand Up @@ -73,17 +73,17 @@ jobs:
cat << 'EOF' > test.py
import random
import time
print("Running complex test...")
time.sleep(2)
# Simulate occasional failures
if random.random() < 0.5:
raise Exception("Random failure!")
print("Success!")
EOF
# Run the script
python test.py
Expand Down

0 comments on commit 8be8012

Please sign in to comment.