On MacOS Big Sur (11.3.1), I'm new to appium-mac2-driver, the code I have try to connect to appium server and receive an error. Even though I mention the automationName on the server and on the client.
[HTTP] --> POST /wd/hub/session
(...)
[debug] [W3C] Calling AppiumDriver.createSession() with args: (...)
[Appium] Could not parse W3C capabilities: 'automationName' can't be blank
[debug] [BaseDriver] Event 'newSessionStarted' logged at 1628283706787 (22:01:46 GMT+0100 (Western European Summer Time))
[debug] [W3C] Encountered internal error running command: InvalidArgumentError: 'automationName' can't be blank
[debug] [W3C] at processCapabilities (/usr/local/lib/node_modules/appium/node_modules/appium-base-driver/lib/basedriver/capabilities.js:217:13)
(...)
The appium server was initiated by appium server -ka 800 --plugins=images -pa /wd/hub --nodeconfig appium-mac2.json. The version of appium installed is 2.0.0-beta.12.
The node configuration have the following capabilities:
{
"capabilities":
[
{
"automationName": "Mac2",
"platform": "Mac",
"platformVersion": "10.15",
"deviceName": "Mac",
"maxInstances": 1,
"appium:bundleId": "com.my.app"
}
]
}
Then the client in java is being connected with the following code block:
DesiredCapabilities caps = new DesiredCapabilities();
caps.setCapability("automationName", "Mac2");
caps.setCapability("platformName", "Mac");
caps.setCapability("bundleId", "com.my.app");
caps.setCapability("newCommandTimeout", 30000);
RemoteWebDriver macDriver = new RemoteWebDriver(new URL("http://localhost:4723/wd/hub"), caps);
This fails while trying to initiate a new session. The code fails at the new RemoteWebDriver line. I've been searching these error is common with other capabilities but not for automationName. Is there anything I doing wrong on the server or even on the client code?