Skip to content

Scheduled SDK Synthetic #97

Scheduled SDK Synthetic

Scheduled SDK Synthetic #97

Workflow file for this run

name: Scheduled SDK Synthetic
on:
schedule:
- cron: "17 * * * *"
workflow_dispatch: {}
permissions:
contents: read
concurrency:
group: python-sdk-synthetic
cancel-in-progress: false
jobs:
health-check:
name: Latest + bounded history
runs-on: ubuntu-latest
timeout-minutes: 10
env:
OILPRICEAPI_KEY: ${{ secrets.OILPRICEAPI_TEST_KEY }}
steps:
- uses: actions/checkout@v7
- name: Set up Python
uses: actions/setup-python@v7
with:
python-version: "3.12"
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install -e '.[dev]'
- name: Keyless demo smoke (always runs)
run: pytest tests/integration/test_demo_contract.py -m live --no-cov -v --timeout=60
- name: Require monitor credential
run: |
if [ -z "$OILPRICEAPI_KEY" ]; then
echo "::error::OILPRICEAPI_TEST_KEY is empty or unset"
exit 1
fi
- name: Run bounded customer-path synthetic
run: python scripts/synthetic_monitor.py --output artifacts/sdk-health.json
- name: Publish receipt in job summary
if: always() && hashFiles('artifacts/sdk-health.json') != ''
run: |
echo '### Python SDK synthetic receipt' >> "$GITHUB_STEP_SUMMARY"
echo '```json' >> "$GITHUB_STEP_SUMMARY"
cat artifacts/sdk-health.json >> "$GITHUB_STEP_SUMMARY"
echo '```' >> "$GITHUB_STEP_SUMMARY"
- name: Upload 30-day receipt
if: always() && hashFiles('artifacts/sdk-health.json') != ''
uses: actions/upload-artifact@v7
with:
name: sdk-health-${{ github.run_id }}
path: artifacts/sdk-health.json
retention-days: 30