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.

Windows: Discrepancy in API When Launching Application vs. Attaching to Existing Application

See original GitHub issue

The problem

Preface: I am using Appium/WebDriverIO to test a native application, specifically on Windows.

I have two testing scenarios:

  1. Having Appium launch a Windows application
  2. Having Appium attach to an existing application

Both are possible with the Windows Appium Driver (the former being most common). Specifically, using the appTopLevelWindow capability.

I run the exact same test code in both instances. However, when I attach to an existing application, one of the API’s I use doesn’t work (500 internal error).

Specifically, the touchScroll, which is apart of the JSON Wire Protocol. And which the Windows Application Driver has full capacity to handle.

Summarize: I am running the exact same test code in two different instances. One when I have Appium launch an application, and one when I have Appium attach to an application. The latter causes a 500: internal error error when using the touchScroll API. An API that I had never had problem with before trying to attach to an application.

Environment

  • Appium version (or git revision) that exhibits the issue: “appium”: “2.0.0-beta.41”
  • Last Appium version that did not exhibit the issue (if applicable):
  • Desktop OS/version used to run Appium: Windows 10
  • Node.js version (unless using Appium.app|exe): Node v14.20
  • Npm or Yarn package manager: Npm v8
  • Mobile platform/version under test: Windows
  • Real device or emulator/simulator:
  • Appium CLI or Appium.app|exe: Via WebDriverIO

Details

If necessary, describe the problem you have been experiencing in more detail.

Link to Appium logs

Please see LOG

Issue Analytics

  • State:closed
  • Created a year ago
  • Comments:9 (1 by maintainers)

github_iconTop GitHub Comments

1reaction
samuelfreibergcommented, Oct 6, 2022

@bwomsm1 I have not. I’ve looked in the logs. The API [POST] calls are the exact same. I’m not sure what is going wrong. My only thought is something with the driver gets spawned differently with Appium when launching the application itself vs. attaching.

I don’t think this is a WinAppDriver issue. My assumption is something with the Appium Windows Driver, but I can’t put my finger on it and it’s driving me crazy.

0reactions
bwomsm1commented, Oct 8, 2022

@samuelfreiberg my scenario is when the appium driver reaches driver_.find_element method

Read more comments on GitHub >

github_iconTop Results From Across the Web

What is the different between API functions AllocConsole and ...
Well, the fundamental difference is: AllocConsole() will create a new console (and attach to it); AttachConsole( ATTACH_PARENT_PROCESS /* -1 ...
Read more >
Stable channel release notes for the Windows App SDK
Provides information about the stable release channel for the Windows App SDK.
Read more >
Debugging in Visual Studio Code
To run or debug a simple app in VS Code, select Run and Debug on the Debug start view or press F5 and...
Read more >
SDK vs. API: What's the Difference? - IBM
Learn about software development kits (SDKs) and Application Programming Interfaces (APIs) and how they improve both software development ...
Read more >
What Is Open API (Public API)? Definition from ... - TechTarget
An open API, also called public API, is an application programming interface ... a difference in that open APIs are shared freely, and...
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