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.

ProxyRequestError: Could not proxy command to remote server when calling `findElement`

See original GitHub issue

The problem

Intermittently my tests fail with ECONNRESET error.

I see the following in Appium server log in that case:

[JSONWP Proxy] Proxying [POST /element] to [POST http://localhost:8207/wd/hub/session/3eb27824-db8a-44d2-a613-9a7defcb85c0/element] with body: {"strategy":"xpath","selector":"//android.widget.TextView[@text=\"Some text\"]/following-sibling::android.widget.ImageView","context":"","multiple":false}
[MJSONWP] Encountered internal error running command: ProxyRequestError: Could not proxy command to remote server. Original error: Error: read ECONNRESET
    at JWProxy.proxy$ (C:\Users\Andrei_Botalov\AppData\Local\Programs\appium-desktop\resources\app\node_modules\appium\node_modules\appium-base-driver\lib\jsonwp-proxy\proxy.js:152:13)
    at tryCatch (C:\Users\Andrei_Botalov\AppData\Local\Programs\appium-desktop\resources\app\node_modules\appium\node_modules\babel-runtime\regenerator\runtime.js:67:40)
    at GeneratorFunctionPrototype.invoke [as _invoke] (C:\Users\Andrei_Botalov\AppData\Local\Programs\appium-desktop\resources\app\node_modules\appium\node_modules\babel-runtime\regenerator\runtime.js:315:22)
    at GeneratorFunctionPrototype.prototype.(anonymous function) [as throw] (C:\Users\Andrei_Botalov\AppData\Local\Programs\appium-desktop\resources\app\node_modules\appium\node_modules\babel-runtime\regenerator\runtime.js:100:21)
    at GeneratorFunctionPrototype.invoke (C:\Users\Andrei_Botalov\AppData\Local\Programs\appium-desktop\resources\app\node_modules\appium\node_modules\babel-runtime\regenerator\runtime.js:136:37)

Environment

  • Appium desktop 1.2.7 (server 1.7.1)
  • Desktop OS/version used to run Appium: Windows 10
  • Mobile platform/version under test: Real Android 6.0 phone connected via USB - Xiaomi Redmi Note 4
  • UiAutomator 2

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Reactions:1
  • Comments:34

github_iconTop GitHub Comments

5reactions
prat3ikcommented, Jan 8, 2019

Please follow below steps:

  1. Make sure appium server is not executing.

  2. Connect your android device with USB, also verify that device is connected properly by using command: adb devices

  3. Execute below commands: adb uninstall io.appium.uiautomator2.server adb uninstall io.appium.uiautomator2.server.test

  4. Start appium server

  5. Start executing appium test cases

5reactions
neogeek13commented, Feb 26, 2018

Changing “automationName”: “uiautomator2” to

“automationName”: “appium”

fixed this for non-primary User accounts. 😃

Read more comments on GitHub >

github_iconTop Results From Across the Web

ProxyRequestError: Could not proxy command to remote ...
Encountered internal error running command: ProxyRequestError: Could not proxy command to remote server. ... to command name 'findElement'
Read more >
appium/appium - Gitter
[MJSONWP (dd25cb08)] Driver proxy active, passing request on via HTTP proxy ... command: ProxyRequestError: Could not proxy command to remote server.
Read more >
Untitled
[MJSONWP] Encountered internal error running command: ProxyRequestError: Could not proxy command to remote server. Original error: Error: read ECONNRESET at ...
Read more >
[Code example]-Appium and protractor just opens the app but ...
... 500 60028 ms - 237 [Chromedriver] ProxyRequestError: Could not proxy command to remote server. Original error: Error: ESOCKETTIMEDOUT at JWProxy.proxy$ ...
Read more >
Appium hidekeyboard() method - Stack Overflow
The Appium method hideKeyboard() is known to be unstable when used on iPhone devices, as listed in Appium's currently known open issues.
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