Skip to content

Commit 070839b

Browse files
committed
debug(ci): add verbose logging for Twilio 0-mocks issue
Print CWD, spec file listing, and full mockd debug log when 0 mocks load. Should reveal whether import path resolution or spec parsing is the root cause.
1 parent 077f8a1 commit 070839b

1 file changed

Lines changed: 11 additions & 2 deletions

File tree

.github/workflows/ci.yaml

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -128,7 +128,10 @@ jobs:
128128
run: |
129129
CONFIG_DIR=$(dirname ${{ matrix.sample.config }})
130130
cd "$CONFIG_DIR"
131-
nohup mockd start -c mockd.yaml --no-auth --log-level warn > /tmp/mockd.log 2>&1 &
131+
echo "CWD: $(pwd)"
132+
echo "Config: $(ls -la mockd.yaml)"
133+
echo "Spec files: $(ls -la *.json *.yaml 2>/dev/null | grep -v mockd.yaml || echo 'none')"
134+
nohup mockd start -c mockd.yaml --no-auth --log-level debug > /tmp/mockd.log 2>&1 &
132135
echo $! > /tmp/mockd.pid
133136
for i in $(seq 1 120); do
134137
curl -sf http://localhost:4290/health > /dev/null 2>&1 && break
@@ -140,7 +143,13 @@ jobs:
140143
exit 1
141144
fi
142145
echo ""
143-
mockd list --json --admin-url http://localhost:4290 | python3 -c "import sys,json; d=json.load(sys.stdin); print(f'Loaded {len(d)} mocks')"
146+
MOCK_COUNT=$(mockd list --json --admin-url http://localhost:4290 | python3 -c "import sys,json; d=json.load(sys.stdin); print(len(d))")
147+
echo "Loaded $MOCK_COUNT mocks"
148+
if [ "$MOCK_COUNT" -eq 0 ]; then
149+
echo "=== mockd log (0 mocks loaded) ==="
150+
cat /tmp/mockd.log | tail -30
151+
exit 1
152+
fi
144153
145154
- name: Smoke test — Stripe
146155
if: matrix.sample.name == 'stripe'

0 commit comments

Comments
 (0)