admc / wd

A node.js client for webdriver/selenium 2.
Other
1.53k stars 402 forks source link

[Appium] W3C capabilities should be provided #636

Closed heychirag closed 2 years ago

heychirag commented 2 years ago

I am getting the following error with Appium v2.0.0-beta. guys over at Appium this is an issue with the driver. Can this be fixed?

% appium  --base-path /wd/hub
[Appium] Welcome to Appium v2.0.0-beta.12
[Appium] Non-default server args:
[Appium]   basePath: /wd/hub
[Appium]   tmpDir: /var/folders/l9/hjmf8hz55hqf2dnhjtbzk9r40000gr/T
[Appium] Attempting to load driver uiautomator2...
[Appium] Attempting to load driver xcuitest...
[Appium] Attempting to load driver mac2...
[Appium] Appium REST http interface listener started on 0.0.0.0:4723
[Appium] Available drivers:
[Appium]   - uiautomator2@1.64.0 (automationName 'UiAutomator2')
[Appium]   - xcuitest@3.42.0 (automationName 'XCUITest')
[Appium]   - mac2@0.12.0 (automationName 'Mac2')
[Appium] Available plugins:
[Appium]   - images@1.1.5
[Appium] No plugins activated. Use the --plugins flag with names of plugins to activate
[HTTP] --> POST /wd/hub/session
[HTTP] {"desiredCapabilities":{"automationName":"XCUITest","bundleId":"com.test.app.dev","platformName":"iOS","udid":"auto","deviceName":"doesntmatter","updatedWDABundleId":"io.appium.WebDriverAgent","xcodeSigningId":"iPhone Developer"}}
[debug] [MJSONWP] Calling AppiumDriver.createSession() with args: [{"xcodeOrgId":"94KV3E626L","automationName":"XCUITest","bundleId":"com.amazon.muse.dev","platformName":"iOS","udid":"auto","deviceName":"doesntmatter","updatedWDABundleId":"io.appium.WebDriverAgent","xcodeSigningId":"iPhone Developer"},null,null]
[debug] [BaseDriver] Event 'newSessionRequested' logged at 1617904183043 (10:49:43 GMT-0700 (Pacific Daylight Time))
[debug] [BaseDriver] Event 'newSessionStarted' logged at 1617904183045 (10:49:43 GMT-0700 (Pacific Daylight Time))
[debug] [W3C] Encountered internal error running command: Error: W3C capabilities should be provided
[debug] [W3C]     at parseCapsForInnerDriver (/usr/local/lib/node_modules/appium/lib/utils.js:57:14)
[debug] [W3C]     at AppiumDriver.createSession (/usr/local/lib/node_modules/appium/lib/appium.js:141:26)
[debug] [W3C]     at commandExecutor (/usr/local/lib/node_modules/appium/node_modules/appium-base-driver/lib/basedriver/driver.js:332:7)
[debug] [W3C]     at AppiumDriver.executeCommand (/usr/local/lib/node_modules/appium/node_modules/appium-base-driver/lib/basedriver/driver.js:346:15)
[debug] [W3C]     at wrappedCmd (/usr/local/lib/node_modules/appium/lib/appium.js:474:28)
[debug] [W3C]     at AppiumDriver.executeWrappedCommand (/usr/local/lib/node_modules/appium/lib/appium.js:541:22)
[debug] [W3C]     at AppiumDriver.executeCommand (/usr/local/lib/node_modules/appium/lib/appium.js:485:28)
[debug] [W3C]     at asyncHandler (/usr/local/lib/node_modules/appium/node_modules/appium-base-driver/lib/protocol/protocol.js:285:34)
[debug] [W3C]     at /usr/local/lib/node_modules/appium/node_modules/appium-base-driver/lib/protocol/protocol.js:411:15
[debug] [W3C]     at Layer.handle [as handle_request] (/usr/local/lib/node_modules/appium/node_modules/express/lib/router/layer.js:95:5)
[debug] [W3C]     at next (/usr/local/lib/node_modules/appium/node_modules/express/lib/router/route.js:137:13)
[debug] [W3C]     at Route.dispatch (/usr/local/lib/node_modules/appium/node_modules/express/lib/router/route.js:112:3)
[debug] [W3C]     at Layer.handle [as handle_request] (/usr/local/lib/node_modules/appium/node_modules/express/lib/router/layer.js:95:5)
[debug] [W3C]     at /usr/local/lib/node_modules/appium/node_modules/express/lib/router/index.js:281:22
[debug] [W3C]     at Function.process_params (/usr/local/lib/node_modules/appium/node_modules/express/lib/router/index.js:335:12)
[debug] [W3C]     at next (/usr/local/lib/node_modules/appium/node_modules/express/lib/router/index.js:275:10)
[debug] [W3C]     at logger (/usr/local/lib/node_modules/appium/node_modules/morgan/index.js:144:5)
[debug] [W3C]     at Layer.handle [as handle_request] (/usr/local/lib/node_modules/appium/node_modules/express/lib/router/layer.js:95:5)
[debug] [W3C]     at trim_prefix (/usr/local/lib/node_modules/appium/node_modules/express/lib/router/index.js:317:13)
[debug] [W3C]     at /usr/local/lib/node_modules/appium/node_modules/express/lib/router/index.js:284:7
[debug] [W3C]     at Function.process_params (/usr/local/lib/node_modules/appium/node_modules/express/lib/router/index.js:335:12)
[debug] [W3C]     at next (/usr/local/lib/node_modules/appium/node_modules/express/lib/router/index.js:275:10)
[debug] [W3C]     at /usr/local/lib/node_modules/appium/node_modules/body-parser/lib/read.js:130:5
[debug] [W3C]     at invokeCallback (/usr/local/lib/node_modules/appium/node_modules/raw-body/index.js:224:16)
[debug] [W3C]     at done (/usr/local/lib/node_modules/appium/node_modules/raw-body/index.js:213:7)
[debug] [W3C]     at IncomingMessage.onEnd (/usr/local/lib/node_modules/appium/node_modules/raw-body/index.js:273:7)
[debug] [W3C]     at IncomingMessage.emit (events.js:327:22)
[debug] [W3C]     at endReadableNT (internal/streams/readable.js:1327:12)
[debug] [W3C]     at processTicksAndRejections (internal/process/task_queues.js:80:21)
[HTTP] <-- POST /wd/hub/session 500 40 ms - 567
jlipps commented 2 years ago

this webdriver client isn't compatible with appium 2. use webdriverio instead.