Closed andinica-salt closed 2 weeks ago
Hello dear, this is a clear case of incorrect configuration.
please follow this link in the user guide: https://shafthq.github.io/docs/Properties/PropertiesList#platform
it's stated that you should configure the target execution address as follows:
local, dockerized, browserstack, host:port, http://host:port/wd/hub
in your case you're using http://127.0.0.1:4723
as per the logs you shared. the engine is trying to compensate for missing wd/hub
and append it to the incorrect url you provided. hence the malformed url exception showing us that the engine is attempting to connect to 4723wd
which is not a valid port.
bottomline is, from your side, kindly either use the host:port
approach like so:
executionAddress=127.0.0.1:4723
or use the http://host:port/wd/hub
approach like so:
executionAddress=http://127.0.0.1:4723/wd/hub
from our side, we should enhance the error message to let you know that you passed an unacceptable parameter.
@MohabMohie here's a GIST of the ExecutionPlatform.properties file. I understand what you're saying, but the error provided by me appears every time the instantiation fails, not only when the URL is malformed. So yeah, the thrown error should be more specific, but this is not the issue here.
I saw the url from the logs dear, and I reexamined it from the attached file. As mentioned in my comment, the URL is provided incorrectly. Kindly use one of the two options I included in my message.
Describe the bug
We currently use the 8.2.20240523 SHAFT engine version. I tried upgrading to the latest one, 8.3.20240829, but I get the following error when trying to run Mobile tests: java.lang.AssertionError: Driver Factory Action "setRemoteDriverInstance" failed. With the following test data "Failed to instantiate remote driver instance.". Root cause: "java.lang.NumberFormatException: Error at index 4 in: "4723wd"" I tried other versions too, and the first one that has this problem for us is 8.2.20240624. I suppose there's been some updates regarding the capabilities / properties and how they are used. We usually get this error when there's a problem with the driver capabilities (bad platform, bad id, etc..). The difference here is that we do not see anything in the appium logs, meaning that there's no actual connection to the appium driver. The same properties/capabilities that work and instantiate the driver on 8.2.20240523 do not work further on.
Link to SHAFT_Engine Console logs
GIST of engine logs
Environment
To Reproduce
Steps to reproduce the behavior:
Expected behavior
Driver is instantiated and tests are run.