写case写好好哒,突然debug的时候就冒出这个错误:

selenium.common.exceptions.WebDriverException: Message: An unknown server-side error occurred while processing the command. Original error: Could not find aapt Please set the ANDROID_HOME environment variable with the Android SDK root directory path.

检查了一圈,没有找到任何原因所在,突然想到刚刚下载了一个新版的platform-tools替换了该路径下(/Users/XXX/Library/Android/sdk/)原有的platform-tools文件夹,采取的是直接copy覆盖的方式……然后恢复到原来的文件夹依然还是报错不干活……使用 appium-doctor检查环境一切ok

后续再次检查了 ANDROID_HOME 及其他环境变量的配置,依然没错……

然后又检查了/Users/XXX/Library/Android/sdk/build-tools下只有一个API Level 27,后续又下载了Level28/26, 依旧failed……

解决方法:

1.重新用android studio更新了一遍sdk (因为当时配置环境的时候为了方便直接安装了android studio来获取一些东西)

2.然后把/Users/XXX/Library/Android/sdk/build-tools/27.0.3下的aapt.exe copy了一份到/Users/XXX/Library/Android/sdk/tools/下

然后就可以愉快的跑起来啦,当然,没搞懂为什么要这样操作一把……

猜想,会不会最近为了解决多个adb冲突,将adb指向airtest路径下,造成环境比较混乱……看来需要清理清理环境了……



Could not find aapt Please set the ANDROID_HOME environment variable with the Android SDK root directory path的更多相关文章

  1. 【已解决】mac上appium报错:“Could not find aapt Please set the ANDROID_HOME environment variable with the Android SDK root directory path”

    按照网上教程配置完appium环境后,真机跑自动化过程,遇到如下报错: appium报错如下: [ADB] Checking whether aapt is present [ADB] The AND ...

  2. Appium问题解决方案(7)- Could not find 'adb.exe' in PATH. Please set the ANDROID_HOME environment variable with the Android SDK root directory path

    背景:运行代码提示找不到ADB An unknown server-side error occurred while processing the command. Original error: ...

  3. mac android studio 出现 Error: SDK location not found. Define location with sdk.dir in the local.properties file or with an ANDROID_HOME environment variable.

      Error: SDK location not found. Define location with sdk.dir in the local.properties file or with a ...

  4. SDK location not found. Define location with sdk.dir in the local.properties file or with an ANDROID_HOME environment variable.

    问题描述: 已经安装了android-sdk 和gradle环境,并配置了环境变量,如下所示: android环境 root@wangju-HP--G4:/home/wangju/Desktop/5i ...

  5. Eclipse导入Gradle时报错:SDK location not found. Define location with sdk.dir in the local.properties file or with an ANDROID_HOME environment variable

    百度查到http://stackoverflow.com/questions/19794200/gradle-android-and-the-android-home-sdk-location 按照其 ...

  6. [Error: Failed to find 'ANDROID_HOME' environment variable. Try setting setting it manually

    7down voteaccepted I don't think its necessary to add everything into path.Just add the JAVA_HOME , ...

  7. Cannot find `aapt.exe`. Please install the Android SDK Build-tools package

    Google has updated their SDK tools ("Android SDK Tools" Rev. 23) in a way that also requir ...

  8. 获取apk信息工具(android SDK的aapt工具)

    aapt命令是android SDK 中的一个工具,功能强大,比如在windows平台获取apk包的信息. 使用该工具准备条件,也即获取aapt.exe文件的方式(2选1即可): 安装android ...

  9. Process 'command '/Users/lidaqiang/Library/Android/sdk/build-tools/27.0.3/aapt'' finished with non-zero exit value 1

    Process 'command '/Users/lidaqiang/Library/Android/sdk/build-tools/27.0.3/aapt'' finished with non-z ...

随机推荐

  1. java 数组转list asList用法

    https://www.cnblogs.com/zheyangsan/p/6910476.html java中数组转list使用Arrays.asList(T... a)方法. 示例: public ...

  2. linux NFS配置案例

    1.查看NFS软件包        [root@server7 ~]# rpm -qa | egrep "nfs|rpcbind" 2.安装NFS和RPC服务        [ro ...

  3. Python基于机器学习方法实现的电影推荐系统

    推荐算法在互联网行业的应用非常广泛,今日头条.美团点评等都有个性化推荐,推荐算法抽象来讲,是一种对于内容满意度的拟合函数,涉及到用户特征和内容特征,作为模型训练所需维度的两大来源,而点击率,页面停留时 ...

  4. ng-class的几种用法

    参考来自 https://www.cnblogs.com/zhoulin1234/p/9587955.html 方法1.逻辑在后面的中括号里面 ng-class="{true : 'chec ...

  5. poj 2559 Largest Rectangle(单调栈)

    Largest Rectangle in a Histogram Time Limit: 1000MS   Memory Limit: 65536K Total Submissions: 26549 ...

  6. luoguP1034 矩形覆盖 x

    P1034 矩形覆盖 题目描述 在平面上有 n 个点(n <= 50),每个点用一对整数坐标表示.例如:当 n=4 时,4个点的坐标分另为:p1(1,1),p2(2,2),p3(3,6),P4( ...

  7. 1003: [ZJOI2006]物流运输

    就我一开始写状压的吗? 调不过 后来发现(直接搜索)直接最短路就行了-- \(f[i]\)表示前\(i\)天最少需要多少 \(f[i] = min(f[j] + dis(j + 1, i))\) 然后 ...

  8. 翻译一篇英文文章,主要是给自己看的——在ASP.NET Core Web Api中如何刷新token

    原文地址 :https://www.blinkingcaret.com/2018/05/30/refresh-tokens-in-asp-net-core-web-api/ 先申明,本人英语太菜,每次 ...

  9. JSON格式标准

    JSON格式 json的基本类型有objects(dicts), arrays(lists), strings, numbers, booleans, and nulls(json中关键字).在一个o ...

  10. 实现图像添加label

    void CmapwingisTest2View::OnToolsAddTiffLayer() { TCHAR szFilters[]= _T("TIFF Files (*.tif)|*.t ...