I confirmed the issue, see the test macro below. I think the right solution is: Kantu has to learn to continue in the - now- active tab once a tab just disappeared.
Current workaround:
Do not let the webpage close the tab itself. Instead:
-
switch back to the main tab
-
then use “selectWindow | tab=closeallother”
{ "Name": "closetabtest", "CreationDate": "2018-12-21", "Commands": [ { "Command": "open", "Target": "https://www.includehelp.com/code-snippets/javascript-function-to-close-current-tab-with-confiration.aspx", "Value": "" }, { "Command": "click", "Target": "link=Click for DEMO →", "Value": "" }, { "Command": "pause", "Target": "2000", "Value": "" }, { "Command": "selectWindow", "Target": "tab=1", "Value": "" }, { "Command": "pause", "Target": "2000", "Value": "" }, { "Command": "click", "Target": "/html/body/p/input", "Value": "" }, { "Command": "pause", "Target": "2000", "Value": "" }, { "Command": "clickAndWait", "Target": "link=Python@POS=3", "Value": "" } ] }