[Bug]: Optional-auth queries never send authorization, so `viewer` is always missing even with an active session
还没有人认领这个 Issue。
评估
调研方向
从 searchActors(matching:limit:cursor:) 开始,并将其请求设置与 issue 中提到的可选身份验证方法进行比较:getAuthorFeed、getListFeed、searchStarterPacks 和 getLabelerServices。检查如何使用 getUserSession() 附加授权信息,同时仍允许未认证的请求。完成标准是:对于有活动会话的已关注账号,viewer 已填充,并且这些查询在没有会话时仍可正常运行。
由索引模型根据 Issue 内容生成。
描述
Summary
searchActors(matching:limit:cursor:) always sends its request to self.pdsURL without authorization, even when a user session exists, so viewer is always missing on the returned actors. Other optional-auth methods such as getAuthorFeed, getListFeed, searchStarterPacks, and getLabelerServices have the same problem.
Reproduction Steps
- Sign in with
ATProtoKitso thatgetUserSession()returns a session. - Call
searchActors(matching:)with a query that matches an account the signed-in user follows. - Inspect
vieweron the returned actors.
Expected Results
viewer is populated (e.g. viewer.followingURI for followed accounts).
Actual Results
viewer is nil for every actor.
What operating systems did you experience this bug?
macOS
Operating System Version
macOS Golden Gate 27.2.1
ATProtoKit Version
0.34.1
Additional Context
The lexicons state "Does not require auth," which permits unauthenticated calls but does not preclude authenticated ones.
- 主要语言
- Swift
- 星标
- 226
- 派生
- 40
- 平均合并
- 2 小时 56 分钟
- 30 天内合并 PR
- 3
环境准备
- 没有 Dockerfile 或 Docker Compose 文件
- 有 Pull Request 模板
- 阅读贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
MasterJ93/ATProtoKit 的其他 Issue
-
bug
难度 2/5 1-3 小时 新手友好度 82/100
MasterJ93/ATProtoKit#354 ·
-
[Feature Enhancement]: Add `sort` parameter to `getQuotes`可能已有人在做 关联的 PR 仍在进行中或已合并。 未关闭enhancement
难度 2/5 1-3 小时 新手友好度 78/100
MasterJ93/ATProtoKit#346 · 1 条评论 ·
-
[Feature Request]: Add `app.bsky.actor.contentVisibilityDeclaration` record support可能已有人在做 关联的 PR 仍在进行中或已合并。 未关闭new feature
难度 3/5 1-2 天 新手友好度 68/100
MasterJ93/ATProtoKit#350 · 4 条评论 ·
-
[Feature Enhancement]: Support scoped mutes (`onlyReposts` / `onlyQuoteposts`) in `muteActor`可能已有人在做 关联的 PR 仍在进行中或已合并。 未关闭enhancement
难度 3/5 1-2 天 新手友好度 72/100
MasterJ93/ATProtoKit#348 · 1 条评论 ·
-
enhancement
难度 4/5 1-2 天 新手友好度 52/100
MasterJ93/ATProtoKit#337 · 3 条评论 ·
查看 MasterJ93/ATProtoKit 的全部 Issue
相似的 Issue
-
enhancement
难度 2/5 1-3 小时 新手友好度 82/100
维护者通常 1 天内回复
-
good first issue help wanted testing
难度 1/5 1 小时以内 新手友好度 78/100
-
area:cli documentation good first issue priority:low
难度 1/5 1 小时以内 新手友好度 94/100
isaaclins/freesnitch#430 ·
维护者通常 1 天内回复
-
enhancement help wanted
难度 2/5 1-3 小时 新手友好度 84/100
heysidhant/appvanish#4 ·
-
bug priority:low status:queued
难度 2/5 1-3 小时 新手友好度 82/100
维护者通常 1 天内回复