etaoin

true.neutral 2023-10-16T20:56:38.680959Z

Hi all! I'm using etaoin to automate some annoying manual steps I need to perform to log in to my AWS account (the annoying part is choosing a radio button from many options). I connect to my running Chrome with open debugger port, but here's a catch - whenever I do (go driver url) , it goes in a random, already opened tab, somewhere out of focus. The driver seems to successfully go through the routine (it's basically wait for element to be visible, click one id, click another id), but nothing actually happens -- when I switch to that tab, nothing was clicked. If the browser doesn't have any existing tabs in the beginning, or if I do a sleep and manage to make the tab etaoin is working with active, it works like a charm. I seemingly can't open a new browser window, as the cookies won't be shared (though maybe I can choose my Chrome profile and that'll work?). The only solution I see so far is to get all the window handles, loop through them, find the one with the title I need, and run the routine from there. Though it surely looks ugly. Also, this method still overwrites a random active tab, which is not ideal. Would you have any suggestions?

lread 2023-10-16T21:43:21.971869Z

@true.neutral I honestly have no clue! Sorry!

true.neutral 2023-11-25T17:36:20.974719Z

Sorry, been a while since I started Slack. @zengxh how would you suggest I open a tab explicitly?

true.neutral 2023-11-25T17:37:03.396929Z

So in the end I resorted to just (go driver url) and cycle through open tabs until I find one with the matching title. 😞 Really ugly, but it works.

Apple 2023-10-18T14:15:26.888979Z

what if you open a new tab before you (go driver url)

true.neutral 2023-10-17T20:36:23.097459Z

@lee no worries!

lread 2023-10-17T21:10:01.878389Z

Let us know what you figure out!