appium-inspector icon indicating copy to clipboard operation
appium-inspector copied to clipboard

feature request: support session id retrieval from Grid 4 /status endpoint instead of just Appium's /sessions endpoint

Open andriiTarasov opened this issue 3 years ago • 2 comments

Appium or Appium Desktop or Appium Inspector?

  • [ ✔️ ] I have verified that my issue does not occur with Appium and should be investigated as an Appium Inspector issue

The problem

Unable to attach to appium session created via selenium grid using port of grid.

Steps to reproduce:

  • Start selenium grid 4.x and appium 2.x
  • Start new appium session via selenium grid like via cURL request (4444 - port for selenium grid 4)
curl 'http://127.0.0.1:4444/session' \ -H 'Connection: keep-alive' \ -H 'accept: application/json' \ -H 'User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) appium-inspector/2022.1.2 Chrome/91.0.4472.164 Electron/13.6.3 Safari/537.36' \ -H 'content-type: application/json;charset=utf-8' \ -H 'Sec-Fetch-Site: cross-site' \ -H 'Sec-Fetch-Mode: cors' \ -H 'Sec-Fetch-Dest: empty' \ -H 'Accept-Language: ru' \ --data-raw '{"capabilities":{"alwaysMatch":{CAPS_DATA},"firstMatch":[{}]},"desiredCapabilities":{desiredCapabilitiesData}}' \ --compressed
  • Open Appium Inspector and using grid port value (4444) set to remote port
  • Open "Attach to Session..." page and check that appium session displayed on select with sessions list

Expected result:

  • Select with sessions display all available sessions from selenium grid

Actual result:

  • Request for reading list of sessions try read sessions from endpoint /sessions, but grid can return session_ids informations from /status endpoint
image

Response from /sessions endpoint - { "value": { "error": "unknown command", "message": "Unable to find handler for (GET) \u002fsessions", "stacktrace": "" } } image

Environment

image
  • Appium: v2.0.0-beta.25
  • Selenium Grid: 4.1.1 (revision e8fcc2cecf)
  • I am running Appium Inspector version 2022.1.2
  • I am on (pick one):
    • [ ✔️] Mac
    • [ ] Windows
    • [ ] Linux

andriiTarasov avatar Feb 01 '22 16:02 andriiTarasov

OK, so this is a feature request to make Grid 4 compatible with the inspector. Got it.

jlipps avatar Feb 07 '22 20:02 jlipps

Perhaps... need to a switch or combine the results of both /sessions and /status..?

KazuCocoa avatar Aug 21 '23 05:08 KazuCocoa