# Troubleshooting Guide
# System Configuration and Installation
# PowerShell Security Issue
Users may encounter the error
PSSecurityException after executing
appium-doctor. Choose one of the methods below to bypass this problem.
Execution Policy configuration via the command line
PowerShell as an administrator and run this command
Set-ExecutionPolicy -ExecutionPolicy Unrestricted -Scope LocalMachine, then approve it by typing
Y and pressing
Enter after the confirmation message appears.
Check this article for more information about
PowerShell Script Execution Policy.
Execution Policy configuration in
Settings apps (only Windows 10)
Settings then navigate to the
For Developers tab under
Update & Security.
Scroll down to the
PowerShell section then click the
Apply button. After that, this section will become blurred.
# Appium Doctor
Appium Doctor is a useful tool to check if your environment was properly configured.
If you have one of the problems below, try re-configuring your environment variables by following this guide after checking that all the necessary components were installed.
If the solution above doesn't work, try to remove and re-install related component such as JDK and Android SDK tools then re-configure the variables. Check this guide for help.
Environment Variables changed, you'll need to re-open the command line windows to reload those variables.
# Create a new project
# Issue with "npm i"
When you've successfully created a new project, the default shell on your pc (e.g: Powershell, zsh) will start automatically and run
npm i to install the necessary packages for the project. Users can also use
npm i to re-install the Gondola Framework.
npm i will have an error after successfully creating a new project, such as this one:
You should try to run
npm cache clean --force and/or delete the
node_modules folder in project's root folder, which contains all downloaded packages, then try running
npm i again.
See the documention here for more on the npm cache.
# Running Tests
# Compatibility between Android SDK Platform-Tools and Appium
Appium (e.g: v1.15.1) is not compatible with some Android SDK Platform-Tools versions (e.g: v29.0.0-5611747). The error message will be displayed as below when user runs the test.
If so, you'll need to upgrade it to the latest Android SDK Platform-Tools version. Follow the steps below to complete this process:
- Open Android Studio.
- Open up the SDK Manager by selecting Tools > SDK Manager from the menu bar.
- Select Android SDK > SDK Tools.
Android SDK Platform-Toolswill be shown as
Update Available. Click the checkbox then click
Applyto update it.
- Click the
OKbutton in the Confirm Change popup and wait for the installation to complete.
enter keyword is unable to clear a text field on iOS 12.x:
This method is used for entering a string into a text field. It clears the text field before filling it with characters.
When using xCode 11 for testing on iOS versions 12.x, this method will not clear the text field, so the entered text will be in the text field along with the initial text. For example, if the field contains the text "username" and you use
enter: john the result will be a text field that contains "usernamejohn"
This issue occurs with Appium and XCode 11. The temporary solution is to use xCode 10 for testing on iOS 12.x. For more information, see the issue report here.