Hacktoberfest 2026:维护者为十月标记出来的 issue,仍然开放、适合新手。 浏览 Hacktoberfest issue

iOS devices: `open <app> <url>` never delivers the URL, `--payload-url` is passed after the bundle ID

已关闭 适合新手
#2,998 0 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看

维护者通常 1 天内回复

还没有人认领这个 Issue。

评估

难度
2/5
预计耗时
1-3 小时
新手友好度
88/100
Issue 类型
缺陷
描述清晰度
描述清楚
活跃度
活跃
技术栈
ios, typescript

调研方向

从 packages/platform-apple/src/core/physical-device-coredevice.ts 中构建启动参数的部分开始,然后将其与 packages/platform-apple/src/core/tests/apps.test.ts 中的预期进行比较。运行相关的 apps 测试,并验证 payload URL 会被作为启动选项处理并传递到实体 iOS 设备,同时继续支持启动参数。

由索引模型根据 Issue 内容生成。

描述

Summary

On a physical iPhone, open <bundle-id> <url> and Maestro openLink launch the app, but the app never receives the URL. The same call with devicectl works when --payload-url comes before the bundle ID.

Cause

The launch arguments put --payload-url after the bundle ID:

https://github.com/callstack/agent-device/blob/16e07572ab28227563fd76ab062cb375c4b7e1db/packages/platform-apple/src/core/physical-device-coredevice.ts#L24-L27

devicectl treats everything after the bundle ID as program arguments for the app:

USAGE: devicectl device process launch [<options>] --device <...> <bundle-identifier-or-path> [<command-line-arguments> ...]

So the app receives --payload-url <url> in its argv and opens no link. The unit test pins the same order:

https://github.com/callstack/agent-device/blob/16e07572ab28227563fd76ab062cb375c4b7e1db/packages/platform-apple/src/core/__tests__/apps.test.ts#L256-L267

Repro

Same device, same app state (app running on its first screen), custom-scheme link to a screen with a visible marker:

Call Link opens
devicectl device process launch --device <udid> <bundle-id> --payload-url <url> no
devicectl device process launch --device <udid> --payload-url <url> <bundle-id> yes
agent-device open <bundle-id> <url> --platform ios --udid <udid> no

A cold launch with --payload-url before the bundle ID also opens the link.

Possible fix

Push --payload-url <url> before the bundle ID, and keep -- <launch args> after it. Update the two expectations in apps.test.ts.

Environment

  • agent-device 0.21.14. Same code in 0.21.15 and on main at 16e0757
  • iPhone 14 Pro, iOS 26.2, USB, CoreDevice backend
  • Xcode 26.4
主要语言
TypeScript
星标
4.8k
派生
315
平均合并
11 小时 25 分钟
30 天内合并 PR
545

环境准备

  • 没有 Dockerfile 或 Docker Compose 文件
  • 没有 Pull Request 模板
  • 阅读贡献指南

从这里开始

  1. 先读完整个 Issue,再读项目的贡献指南。
  2. 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
  3. Fork 仓库,在一个分支上完成修改。
  4. 提交 Pull Request,并在描述里引用这个 Issue 编号。

callstack/agent-device 的其他 Issue

查看 callstack/agent-device 的全部 Issue

相似的 Issue

更多 TypeScript Issue

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。