Skip to content
This repository was archived by the owner on Apr 14, 2026. It is now read-only.

Commit bfbacc0

Browse files
Merge pull request #311 from balancer/debug/raw-githubusercontent
add debug workflow for raw.githubusercontent.com CI issue
2 parents bd267c5 + 76579a3 commit bfbacc0

1 file changed

Lines changed: 48 additions & 0 deletions

File tree

Lines changed: 48 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,48 @@
1+
name: Debug raw.githubusercontent.com
2+
3+
on:
4+
workflow_dispatch:
5+
6+
jobs:
7+
debug:
8+
runs-on: ubuntu-latest
9+
steps:
10+
- name: Test raw.githubusercontent.com responses
11+
run: |
12+
for URL in \
13+
"https://raw.githubusercontent.com/balancer/bal_addresses/refs/heads/main/extras/chains.json" \
14+
"https://raw.githubusercontent.com/balancer/bal_addresses/main/extras/chains.json" \
15+
"https://raw.githubusercontent.com/BalancerMaxis/bal_addresses/main/extras/chains.json"; do
16+
echo "=== $URL ==="
17+
echo "--- Headers ---"
18+
curl -sI "$URL"
19+
echo "--- Status code ---"
20+
curl -s -o /dev/null -w "HTTP %{http_code}\n" "$URL"
21+
echo "--- First 200 bytes ---"
22+
curl -s "$URL" | head -c 200
23+
echo ""
24+
echo ""
25+
done
26+
27+
- name: Test Python requests behavior
28+
run: |
29+
pip3 install requests
30+
python3 -c "
31+
import requests
32+
urls = [
33+
'https://raw.githubusercontent.com/balancer/bal_addresses/refs/heads/main/extras/chains.json',
34+
'https://raw.githubusercontent.com/balancer/bal_addresses/main/extras/chains.json',
35+
]
36+
for url in urls:
37+
print(f'=== {url} ===')
38+
resp = requests.get(url)
39+
print(f'Status: {resp.status_code}')
40+
print(f'Content-Type: {resp.headers.get(\"content-type\")}')
41+
print(f'Body[:200]: {resp.text[:200]}')
42+
try:
43+
resp.json()
44+
print('json(): OK')
45+
except Exception as e:
46+
print(f'json(): FAILED - {e}')
47+
print()
48+
"

0 commit comments

Comments
 (0)