@@ -68,16 +68,26 @@ check_prerequisites() {
6868wait_for_agent_ready () {
6969 local name=$1
7070 local logfile=" /tmp/agentex-${name} .log"
71- local timeout=30 # seconds
71+ local timeout=45 # seconds - increased to account for package installation time
7272 local elapsed=0
7373
74- echo -e " ${YELLOW} ⏳ Waiting for ${name} agent to be ready...${NC} "
74+ if [ " $QUIET_MODE " = false ]; then
75+ echo -e " ${YELLOW} ⏳ Waiting for ${name} agent to be ready...${NC} "
76+ fi
7577
7678 while [ $elapsed -lt $timeout ]; do
77- if grep -q " Application startup complete" " $logfile " 2> /dev/null || \
78- grep -q " Running workers for task queue" " $logfile " 2> /dev/null; then
79- echo -e " ${GREEN} ✅ ${name} agent is ready${NC} "
80- return 0
79+ # Check if agent is successfully registered
80+ if grep -q " Successfully registered agent" " $logfile " 2> /dev/null; then
81+
82+ # For temporal agents, also wait for workers to be ready
83+ if [[ " $tutorial_path " == * " temporal" * ]]; then
84+ # This is a temporal agent - wait for workers too
85+ if grep -q " Running workers for task queue" " $logfile " 2> /dev/null; then
86+ return 0
87+ fi
88+ else
89+ return 0
90+ fi
8191 fi
8292 sleep 1
8393 (( elapsed++ ))
@@ -285,7 +295,8 @@ run_test() {
285295
286296 # Always show pytest output, even in quiet mode
287297 echo " ========== PYTEST OUTPUT =========="
288- uv run pytest tests/test_agent.py -v -s
298+ # Use unbuffered output for real-time visibility
299+ PYTHONUNBUFFERED=1 uv run pytest tests/test_agent.py -v -s --tb=short
289300 exit_code=$?
290301 echo " ========== END PYTEST OUTPUT =========="
291302
0 commit comments