Skip to content

The fastest, litest AI Gateway. Rust core with Python SDK. Call 100+ LLM APIs in OpenAI (or native) format with cost tracking, guardrails, load balancing, and logging [Bedrock, Azure, OpenAI, Anthropic, OpenAI, VertexAI, vLLM, Nvidia NIM]

Add job timeout and use jq for safe JSON construction

Julio Quinteros Proa2946e2cc803
diff --git a/.github/workflows/run_observatory_tests.yml b/.github/workflows/run_observatory_tests.yml
index b6f6e9f19d3..f11e46665a6 100644
--- a/.github/workflows/run_observatory_tests.yml
+++ b/.github/workflows/run_observatory_tests.yml
@@ -30,6 +30,7 @@ env:
jobs:
observatory-tests:
runs-on: ubuntu-latest
+ timeout-minutes: 30
steps:
- name: Checkout repository
uses: actions/checkout@v4
@@ -99,15 +100,19 @@ jobs:
id: trigger
run: |
OBSERVATORY_URL="${{ secrets.OBSERVATORY_URL }}"
+ PAYLOAD=$(jq -n \
+ --arg url "${{ env.TUNNEL_URL }}" \
+ --arg key "${{ env.LITELLM_MASTER_KEY }}" \
+ '{
+ deployment_url: $url,
+ api_key: $key,
+ test_suite: "TestOAIAzureRelease",
+ models: ["gpt-4o-mini", "gpt-4o"]
+ }')
RESPONSE=$(curl -s -w "\n%{http_code}" -X POST "${OBSERVATORY_URL}/run-test" \
-H "Content-Type: application/json" \
-H "X-LiteLLM-Observatory-API-Key: ${{ secrets.OBSERVATORY_API_KEY }}" \
- -d '{
- "deployment_url": "${{ env.TUNNEL_URL }}",
- "api_key": "${{ env.LITELLM_MASTER_KEY }}",
- "test_suite": "TestOAIAzureRelease",
- "models": ["gpt-4o-mini", "gpt-4o"]
- }')
+ -d "$PAYLOAD")
HTTP_CODE=$(echo "$RESPONSE" | tail -1)
BODY=$(echo "$RESPONSE" | head -n -1)
echo "Response ($HTTP_CODE): $BODY"