LCORE-536 Add error handling for bad llama-stack URLs; no more silent fails#1109
Conversation
|
@radofuchs Could you PTAL? |
|
Warning Rate limit exceeded
⌛ How to resolve this issue?After the wait time has elapsed, a review can be triggered using the We recommend that you space out your commits to avoid hitting the rate limit. 🚦 How do rate limits work?CodeRabbit enforces hourly rate limits for each developer per organization. Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout. Please see our FAQ for further information. WalkthroughThe PR introduces stricter URL validation for Llama Stack configuration by changing the url field type from Optional[str] to Optional[AnyHttpUrl], adds error handling for API connection failures during startup, and updates the client to properly stringify URLs before initialization. Changes
Estimated code review effort🎯 2 (Simple) | ⏱️ ~10 minutes Possibly related PRs
Suggested reviewers
✨ Finishing touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
959a6bd to
b75a7ac
Compare
Description
Adding proper error handling for incorrect llama-stack URL configurations that previously failed silently at startup. Malformed URLs and URLs with wrong scheme are now rejected; unreachable hosts result into error message.
Type of change
Tools used to create PR
Identify any AI code assistants used in this PR (for transparency and review context)
Related Tickets & Documents
Checklist before requesting a review
Testing
llama_stack:
url: not-a-valid-url
llama_stack.url
Input should be a valid URL, relative URL without a base
Summary by CodeRabbit
Release Notes
Bug Fixes
Improvements