Open
Conversation
When users log into Kiro via an organization and enter a region like us-east-2, the credentials file stores that region. Previously, _load_credentials_from_file would use it to override _api_host and _q_host, directing all API calls to https://q.us-east-2.amazonaws.com which does not exist. Fix: mirror the SQLite path behaviour — store the credentials region as _sso_region (used only for the auth/refresh URL) and leave _api_host/_q_host controlled exclusively by KIRO_REGION env var (default us-east-1). Agent-Logs-Url: https://github.com/d0zingcat/kiro-gateway/sessions/c2767caa-9730-4857-9f8a-8e5d0bf74d47 Co-authored-by: d0zingcat <8235790+d0zingcat@users.noreply.github.com>
fix: credentials file region must not override Kiro API host
|
Thanks for the PR! 🎉 Before merge, we need a one-time CLA confirmation. Full CLA text: Please reply once with: You need to write once, all further messages from me can be ignored. |
新增 KIRO_API_REGION 环境变量,允许独立配置 Q Developer API 端点区域。 解决 q.amazonaws.com 仅在特定区域存在,而 SSO 区域可能不同导致的 DNS 失败问题。
54d0345 to
56c6729
Compare
|
Thanks for the PR! 🎉 Before merge, we need a one-time CLA confirmation. Full CLA text: Please reply once with: You need to write once, all further messages from me can be ignored. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
摘要
KIRO_API_REGION环境变量,独立控制 Q Developer API 端点区域KIRO_REGION继续用于 SSO/OIDC token 刷新端点,KIRO_API_REGION用于 Q API 端点q.amazonaws.com仅在特定区域存在,SSO 区域不同时导致 DNS 失败的问题测试计划
KIRO_REGION=us-east-2+KIRO_API_REGION=us-east-1时 Q API 请求正常KIRO_API_REGION时默认使用us-east-1(向后兼容)tests/unit/test_auth_manager.py中新增的TestKiroAuthManagerApiRegionSeparation测试类🤖 Generated with Claude Code