process.executeAsync(); Exception
维护者通常 5 天内回复
还没有人认领这个 Issue。
评估
- 难度
- 4/5
- 预计耗时
- 3-5 天
- 新手友好度
- 25/100
- Issue 类型
- 缺陷
- 描述清晰度
- 需要澄清
- 活跃度
- 停滞
- 技术栈
- java
- 领域
- mobile-dev, tooling
调研方向
从 AppiumDriverLocalService.java 的 start() 开始,重点查看 process.executeAsync() 调用及其周围的异常处理。跟踪 Node.js 可执行文件、参数、环境和进程输出是如何提供的,然后利用报告的失败上下文确定原因。当本地 Appium 服务器能够在不出现此异常的情况下启动,并且失败行为得到验证时,即视为完成。
由索引模型根据 Issue 内容生成。
描述
下記はappiumソース:AppiumDriverLocalService.javaのstartメソッド:
/**
-
Starts the defined appium server.
-
@throws AppiumServerHasNotBeenStartedLocallyException If an error occurs while spawning the child process.
-
@see #stop()
*/
public void start() throws AppiumServerHasNotBeenStartedLocallyException {
lock.lock();
try {
if (isRunning()) {
return;
}try { process = new CommandLine(this.nodeJSExec.getCanonicalPath(), nodeJSArgs.toArray(new String[]{})); process.setEnvironmentVariables(nodeJSEnvironment); process.copyOutputTo(stream); process.executeAsync(); //出了异常,在官网上提问下解决方案:这段代码出错一般是什么原因?如何让这个“进场创建”不出错? ping(startupTimeout, timeUnit); } catch (Throwable e) { destroyProcess(); String msgTxt = "The local appium server has not been started. " + "The given Node.js executable: " + this.nodeJSExec.getAbsolutePath() + " Arguments: " + nodeJSArgs.toString() + " " + "\n"; if (process != null) { String processStream = process.getStdOut(); if (!StringUtils.isBlank(processStream)) { msgTxt = msgTxt + "Process output: " + processStream + "\n"; } } throw new AppiumServerHasNotBeenStartedLocallyException(msgTxt, e); }} finally {
lock.unlock();
}
}
- 主要语言
- Java
- 星标
- 1.3k
- 派生
- 755
- 平均合并
- 5 天 14 小时
- 30 天内合并 PR
- 8
环境准备
- 没有 Dockerfile 或 Docker Compose 文件
- 有 Pull Request 模板
- 没有贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
appium/java-client 的其他 Issue
-
难度 5/5 一周以上 新手友好度 25/100
appium/java-client#2426 ·
维护者通常 5 天内回复
-
bug
难度 4/5 3-5 天 新手友好度 50/100
appium/java-client#2372 ·
维护者通常 5 天内回复
-
难度 5/5 一周以上 新手友好度 30/100
appium/java-client#2368 ·
维护者通常 5 天内回复
-
难度 2/5 1-3 小时 新手友好度 30/100
appium/java-client#2341 · 1 条评论 ·
维护者通常 5 天内回复
-
难度 5/5 一周以上 新手友好度 15/100
appium/java-client#2323 ·
维护者通常 5 天内回复
查看 appium/java-client 的全部 Issue
相似的 Issue
-
难度 2/5 1-3 小时 新手友好度 88/100
refinedmods/refinedstorage2#1414 · 1 条评论 ·
-
bug
难度 2/5 1-3 小时 新手友好度 78/100
-
难度 2/5 1-3 小时 新手友好度 73/100
google/differential-privacy#489 ·
-
难度 1/5 1 小时以内 新手友好度 78/100
维护者通常 1 天内回复
-
link-check link-check:manual
难度 2/5 1-3 小时 新手友好度 85/100