question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

appium should be a peer dep of extentensions

See original GitHub issue

The problem

I have made some tries to run tests on iOS using XCUiTest and on Android using Espresso with Appium 2.0, but each time that I try to create the session, Appium shows an internal error.

Environment

  • Appium version v2.0.0-beta 28:
  • Node.js version: v14.17.0
  • Npm or Yarn package manager: NPM
  • Mobile platform/version under test: iOS & Android
  • Real device or emulator/simulator: Simulator & Device
  • Appium CLI or Appium.app|exe: Appium command line

Details

I have installed the drivers:

  • xcuitest version 4.3.5
  • uiautomator2 version 2.0.7
  • espresso verision 2.2.1

iOS ` [debug] [AppiumDriver@94a2] Event ‘newSessionRequested’ logged at 1649674844863 (13:00:44 GMT+0200 (Central European Summer Time)) [Appium] Attempting to find matching driver for automationName ‘XCUITest’ and platformName ‘iOS’ [Appium] The ‘xcuitest’ driver was installed and matched caps. [Appium] Will require it at /Users/SYS_CIBER_ADMIN/.appium/node_modules/appium-xcuitest-driver [debug] [Appium] Requiring driver at /Users/SYS_CIBER_ADMIN/.appium/node_modules/appium-xcuitest-driver [AppiumDriver@94a2] Appium v2.0.0-beta.28 creating new XCUITestDriver (v4.3.5) session [AppiumDriver@94a2] Checking BaseDriver versions for Appium and XCUITestDriver [AppiumDriver@94a2] Appium’s BaseDriver version is 8.4.0 [AppiumDriver@94a2] XCUITestDriver’s BaseDriver version is 8.3.1 [debug] [AppiumDriver@94a2] Event ‘newSessionStarted’ logged at 1649674844867 (13:00:44 GMT+0200 (Central European Summer Time))

[debug] [AppiumDriver@94a2] Encountered internal error running command: TypeError: driverInstance.assignServer is not a function [debug] [AppiumDriver@94a2] at AppiumDriver.createSession (/usr/local/lib/node_modules/appium/lib/appium.js:282:22) [debug] [AppiumDriver@94a2] at commandExecutor (/usr/local/lib/node_modules/appium/node_modules/@appium/base-driver/lib/basedriver/driver.js:74:9) [debug] [AppiumDriver@94a2] at AppiumDriver.executeCommand (/usr/local/lib/node_modules/appium/node_modules/@appium/base-driver/lib/basedriver/driver.js:94:15) [debug] [AppiumDriver@94a2] at processTicksAndRejections (internal/process/task_queues.js:95:5) [debug] [AppiumDriver@94a2] at defaultBehavior (/usr/local/lib/node_modules/appium/lib/appium.js:601:16) [debug] [AppiumDriver@94a2] at AppiumDriver.executeWrappedCommand (/usr/local/lib/node_modules/appium/lib/appium.js:683:16) [debug] [AppiumDriver@94a2] at AppiumDriver.executeCommand (/usr/local/lib/node_modules/appium/lib/appium.js:612:17) [debug] [AppiumDriver@94a2] at asyncHandler (/usr/local/lib/node_modules/appium/node_modules/@appium/base-driver/lib/protocol/protocol.js:313:19) [HTTP] <-- POST /wd/hub/session 500 7 ms - 589 `

Android ` [debug] [AppiumDriver@94a2] Event ‘newSessionRequested’ logged at 1649675270462 (13:07:50 GMT+0200 (Central European Summer Time)) [Appium] Attempting to find matching driver for automationName ‘Espresso’ and platformName ‘android’ [Appium] The ‘espresso’ driver was installed and matched caps. [Appium] Will require it at /Users/SYS_CIBER_ADMIN/.appium/node_modules/appium-espresso-driver [debug] [Appium] Requiring driver at /Users/SYS_CIBER_ADMIN/.appium/node_modules/appium-espresso-driver [AppiumDriver@94a2] Appium v2.0.0-beta.28 creating new EspressoDriver (v2.2.1) session [AppiumDriver@94a2] Checking BaseDriver versions for Appium and EspressoDriver [AppiumDriver@94a2] Appium’s BaseDriver version is 8.4.0 [AppiumDriver@94a2] EspressoDriver’s BaseDriver version is 8.3.1 [debug] [AppiumDriver@94a2] Event ‘newSessionStarted’ logged at 1649675270465 (13:07:50 GMT+0200 (Central European Summer Time))

[debug] [AppiumDriver@94a2] Encountered internal error running command: TypeError: driverInstance.assignServer is not a function [debug] [AppiumDriver@94a2] at AppiumDriver.createSession (/usr/local/lib/node_modules/appium/lib/appium.js:282:22) [debug] [AppiumDriver@94a2] at commandExecutor (/usr/local/lib/node_modules/appium/node_modules/@appium/base-driver/lib/basedriver/driver.js:74:9) [debug] [AppiumDriver@94a2] at AppiumDriver.executeCommand (/usr/local/lib/node_modules/appium/node_modules/@appium/base-driver/lib/basedriver/driver.js:94:15) [debug] [AppiumDriver@94a2] at processTicksAndRejections (internal/process/task_queues.js:95:5) [debug] [AppiumDriver@94a2] at defaultBehavior (/usr/local/lib/node_modules/appium/lib/appium.js:601:16) [debug] [AppiumDriver@94a2] at AppiumDriver.executeWrappedCommand (/usr/local/lib/node_modules/appium/lib/appium.js:683:16) [debug] [AppiumDriver@94a2] at AppiumDriver.executeCommand (/usr/local/lib/node_modules/appium/lib/appium.js:612:17) [debug] [AppiumDriver@94a2] at asyncHandler (/usr/local/lib/node_modules/appium/node_modules/@appium/base-driver/lib/protocol/protocol.js:313:19) [HTTP] <-- POST /wd/hub/session 500 7 ms - 589 `

Code To Reproduce Issue [ Good To Have ]

I run Appium from a terminal with this command:

Appium -pa /wd/hub

And I’m launching the sessions from the Appium-Inspector with the following capabilities

iOS { "platformName": "iOS", "appium:deviceName": "iPhone 11 Pro Max", "appium:automationName": "XCUITest", "appium:language": "es", "appium:locale": "ES", "appium:platformVersion": "14.2" }

Android { "platformName": "Android", "appium:deviceName": "pixel_2_9_0", "appium:automationName": "Espresso", "appium:language": "es", "appium:locale": "ES", "appium:app": "MY_APK_FILE", }

If I do the same tests with the Appium Desktop v1.21 or v1.22.2, I can create the session and connect with Appium properly.

Issue Analytics

  • State:closed
  • Created a year ago
  • Comments:35 (16 by maintainers)

github_iconTop GitHub Comments

2reactions
boneskullcommented, Apr 11, 2022

Yeah, I’ll put it on my list

1reaction
jlippscommented, Apr 13, 2022

@JuanCarlos-Arceredillo that’s a separate issue, do you mind opening a new issue so we can treat it on its own.

Read more comments on GitHub >

github_iconTop Results From Across the Web

extensions should have a peer dependency on appium by boneskull ...
For most extensions, a peer dependency of ^2.0.0 will be sufficient (we should not recommend using * ). For others, a more specific...
Read more >
npm WARN ... requires a peer of ... but none is installed. You ...
"A requires a peer of B but none was installed". Consider it as "A requires one of B's peers but that peer was...
Read more >
Desired Capabilities - Appium
This set of Desired Capabilities expresses the desire for Appium to begin an automation session on an iPhone 7 simulator with iOS 11,...
Read more >
Appium reviews, rating and features 2022 - PeerSpot
Appium is an open-source mobile application development tool that is designed to give users complete control of their application development process.
Read more >
Top 50 + Appium Interview Question and Answers | KITS
Q.How Can I Exchange Data Between My Test And The App I Am Testing? Ans: Appium, actually the WebDriver specification, is not made...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found