Android leases over HTTP give no adb serial: udid is the AVD name
维护者通常 1 天内回复
还没有人认领这个 Issue。
评估
- 难度
- 2/5
- 预计耗时
- 1-3 小时
- 新手友好度
- 78/100
- Issue 类型
- 缺陷
- 描述清晰度
- 描述清楚
- 活跃度
- 活跃
- 技术栈
- android, typescript
调研方向
阅读第71行附近的src/http/tracker.ts以及src/contract/schemas.ts中第211行和第272行附近的设备 schema;将 lease 响应与 CLI 的device.address输出进行比较。检查第918行和第948行附近的 Android 驱动字段,以确认序列号来源。当 HTTP lease 对象公开设备地址(包括 Android 上的 adb 序列号),且响应契约也体现这一点时,工作即告完成。
由索引模型根据 Issue 内容生成。
描述
What happened
A lease granted over the HTTP API gives no way to reach an Android emulator with adb. The lease object's udid is the device's driver id (device.driverDeviceId, src/http/tracker.ts:71). For an Android emulator that is the AVD name (simlock_<uuid>), not the adb serial (emulator-5554) that adb -s needs. No HTTP response carries the serial: the lease object has no address field, although the contract's device record has one (src/contract/schemas.ts:211,272) and the CLI's lease line includes device.address.
So a remote agent that leases an Android device over HTTP cannot run adb -s <serial> … through POST /v1/leases/{id}/exec without first running adb devices and then adb -s <serial> emu avd name on each serial to find its own. iOS is not affected, because a simulator's driver id and its address are both the UDID.
What you expected
The HTTP lease object names the address to point tools at (the adb serial on Android, the UDID on iOS), the same value the CLI prints as device.address.
How to reproduce
- On a worker with Android set up and HTTP on, create an agent token:
simlock token create --role agent. curl -X POST http://127.0.0.1:4701/v1/lease-requests -H "Authorization: Bearer <secret>" -H 'Content-Type: application/json' -d '{"platform":"android","model":"Pixel 8"}', then wait until the request isgranted.- Look at the lease object:
udidissimlock_…, and no field holdsemulator-5554. - Compare
simlock lease --platform android --device "Pixel 8" --detach, whosedevice.addressis the serial.
Environment
main at 4cc44f82. Found while writing the website's "Remote agents over HTTP" page (PR #816), which documents the adb devices workaround.
Logs and evidence
src/http/tracker.ts:71:udid: device.driverDeviceIdsrc/drivers/android/index.ts:948: a running emulator'saddressisrunning.serial;:918: itsdeviceIdis the AVD name.
Written by an agent.
- 主要语言
- TypeScript
- 星标
- 20
- 派生
- 2
- 平均合并
- 8 小时 10 分钟
- 30 天内合并 PR
- 354
环境准备
这个项目没有提供开发容器、Dockerfile 或贡献指南,环境需要你自己搭建:先看它的 README,通用步骤见我们的新手贡献指南。
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
callstackincubator/simlock 的其他 Issue
-
bug:new
难度 2/5 1-3 小时 新手友好度 67/100
callstackincubator/simlock#871 ·
维护者通常 1 天内回复
-
bug:triage
难度 2/5 1-3 小时 新手友好度 76/100
callstackincubator/simlock#778 · 1 条评论 ·
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 70/100
callstackincubator/simlock#639 · 1 条评论 ·
维护者通常 1 天内回复
-
bug:new flaky-test
难度 3/5 1-2 天 新手友好度 62/100
callstackincubator/simlock#886 ·
维护者通常 1 天内回复
-
bug:new
难度 4/5 3-5 天 新手友好度 68/100
callstackincubator/simlock#865 ·
维护者通常 1 天内回复
查看 callstackincubator/simlock 的全部 Issue
相似的 Issue
-
createAI: the ai peer range allows ai@6, which the provider cannot work with可能已有人在做 @akhil9tiet 今天认领。 未关闭bug
难度 1/5 1 小时以内 新手友好度 83/100
cloudflare/agents#2690 · 3 条评论 ·
维护者通常 1 天内回复
-
[fullsend] E2E: theme — global-header ignores app.branding.fullLogo (RHDHBUGS-3670)可能已有人在做 @fullsend-ai-coder 今天认领。 未关闭e2e-failure ready-to-code
难度 1/5 1 小时以内 新手友好度 78/100
redhat-developer/rhdh-plugin-export-overlays#4503 · 1 条评论 ·
维护者通常 1 天内回复
-
needs triage 📥
难度 1/5 1 小时以内 新手友好度 86/100
ethereum/ethereum-org-website#19601 ·
维护者通常 1 天内回复
-
bug
难度 2/5 1-3 小时 新手友好度 76/100
cloudscape-design/components#5184 ·
维护者通常 2 天内回复
-
难度 2/5 1-3 小时 新手友好度 68/100
agilepathway/label-checker#805 ·
维护者通常 1 天内回复