mirror of
https://github.com/BenedictKing/kiro.rs.git
synced 2026-04-25 06:55:50 +03:00
[PR #102] fix(token): handle missing access_token and simplify refresh headers #52
Labels
No labels
pull-request
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/kiro.rs#52
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Original Pull Request: https://github.com/hank9999/kiro.rs/pull/102
State: open
Merged: No
改动说明
fix: 处理 为空的情况
之前当 为 时,会直接进入过期时间判断逻辑,可能导致意外行为。现在提前判断,若 不存在则直接视为已过期,触发刷新流程。
fix: 修正 Social Token 刷新的 User-Agent 格式
将 User-Agent 格式从
KiroIDE-{version}-{machineId}修正为与官方客户端一致的格式:aws-sdk-js/1.0.18 ua/2.1 os/windows lang/js md/nodejs#20.16.0 api/codewhispererstreaming#1.0.18 m/E KiroIDE-{version}-{machineId}同时移除了多余的请求头(
Accept-Encoding、host、Connection等)。fix: 简化 IdC Token 刷新的请求头
移除了 IdC 刷新请求中冗余的请求头(
Host、Connection、x-amz-user-agent、Accept等),保留必要的Content-Type。chore: 增加 IdC Token 刷新的 tracing 日志
在 IdC 刷新流程的关键节点添加了日志输出,便于排查认证问题。