Coming from Java world, one of my colleagues shown me ARC https://github.com/appium/ruby_console and I loved it a lot.
This helps a lot to find out elements on page, interact with them, play around and finally add / update automation script.
Please review if it's feasible to add this feature into the desktop app itself.
Thanks,
Vikram
Hi @vikramvi,
Currently, we have the ability in our NodeJS client (https://www.github.com/admc/wd) to attach to an existing session, so all you need to do is start a session from Appium Desktop, copy the sessionId, open a terminal, install WD and run node.
npm install wd
node
...and then input this (_warning: this is untested_)
var wd = require('wd');
var driver = wd.promiseChainRemote({
hostname: '<hostname>',
port: '<port>',
username: '<username>',
https: true | false,
});
driver.attach(sessionID);
From there, you can run ad-hoc commands on the session.
As for adding it as a feature to Appium Desktop (ie: a feature where you can 1. open a session; 2. select a client from a dropdown; 3. drive that session from a REPL), that's certainly something that would be useful and we could put in the backlog (we would also need to update some of the clients because they don't all have the attach functionality).
It may take some time for us to get around to implementing such a feature, but if anyone is interested we do take pull requests.
A REPL isn't an Appium Desktop feature request, it's a client binding feature request. I'm going to close this here; if you want a JAVA-style REPL, maybe talk tot he Java client folks?
Please reconsider add a penal called "Console" in Appium Inspector, just like devtools in chrome.
The target language in "Console" could either be javascript (use wd driver) or some DSL (say, the S-EXP sent to "appium-client-command-request", e.g. (click {accessibility-id: "More Option"}))
Most helpful comment
Hi @vikramvi,
Currently, we have the ability in our NodeJS client (https://www.github.com/admc/wd) to attach to an existing session, so all you need to do is start a session from Appium Desktop, copy the sessionId, open a terminal, install WD and run node.
...and then input this (_warning: this is untested_)
From there, you can run ad-hoc commands on the session.
As for adding it as a feature to Appium Desktop (ie: a feature where you can 1. open a session; 2. select a client from a dropdown; 3. drive that session from a REPL), that's certainly something that would be useful and we could put in the backlog (we would also need to update some of the clients because they don't all have the
attachfunctionality).It may take some time for us to get around to implementing such a feature, but if anyone is interested we do take pull requests.