I’m new to Kantu. I have a macOS server and I thought a scheduled Kantu macro would be a perfect way for me to post my oldest “draft” comic to webtoons. com, which doesn’t natively support scheduling.
So I wrote a macro that logs into Webtoon, navigates to the “edit episode” page, pages through until it finds the oldest draft, publishes it, then logs out.
It worked! I was so proud of myself. I set it up to work on my server, I scheduled it to run on the days I wanted it to, and it was perfect. Then, after running three times, it began to stop only a few steps in, on the first clickAndWait command.
This is the start of my macro:
Command | Target | Value |
---|---|---|
open | WEBTOON - Read Comics, Manga & Manhwa | |
type | id=emailId | user @example.com |
type | id=password | letmein |
click | link=Log In | |
clickAndWait | css=a#btnLogIn |
There’s more in my macro, but it’s not relevant, because the problem is the last command here, clickAndWait css=a#btnLogIn. If I run the macro and it stops at this command due to an error, I can click a#btnLogIn manually, then right click and “Run from here” on the line after it (which includes some more clickAndWait commands, strangely!), and the macro completes successfully.
This is the error:
‘clickAndWait’ failed. No page load event detected after 10 seconds. Try ‘click’ instead. Error detail: still same ipc secret
The issue is not the ten seconds, as nothing ever loads, as I watch the browser, I don’t see the visual sign that Kantu found and targeted the a#btnLogIn. From all I can tell, IPC is inter-process communication and so this error relates to Kantu having some issue telling the Chrome tab what to do. But I feel like I have a pretty ideal setup — a fresh Chrome install, used for nothing else, no extra extensions, and my scheduler simply starts up Chrome, loads a saved .html Kantu macro, waits a few minutes then quits Chrome.
Is there anything I can do to stop this “still same ipc secret” error? It’s not just a mysterious Kantu bug, is it? I’d really love to sort this macro out so it runs reliably.
I’m using Google Chrome 76.0.3809.100 and Kantu 5.1.9 on macOS 10.11.16.
For what it’s worth, I tried:
- Using xpath to target the a#btnLogIn. Same error.
- Using click and manually pausing for a few seconds. Same error (but this time, for click, not clickAndWait).
- Running the macro on my home setup (same Chrome and Kantu versions, but macOS 10.14.6.) Same error (unless it decides to work, which sometimes it does).
- Downgrading Kantu to 4.2.6, since some forum post mentioned it as a solution to the “still same ipc secret” error. It didn’t change anything.
- Latest Firefox and latest Kantu. Encountered a new problem, something related to “getclientrects undefined”, that stopped the macro from even starting.
- Firefox 68.0.2 ESR, per some forum post that said ESR worked when new Firefox didn’t. Same getclientsrect error.
- Rebooting. No dice (and this not a long-term solution for my server, anyway)
Unfortunately, this is a problem that comes and goes. I actually wrote this post a week ago but didn’t post it because by the time I finished writing, it started working again. So I can’t replicate this error reliably, but right now as I write this forum post, it’s failing again.
If it helps to know, I also did at one point start seeing the “IPC Promise has been Destroyed” error, but I can’t remember when.
Help! If you can. It’d be greatly appreciated, because this macro is otherwise super cool!
Full JSON format macro
{ "Name": "Webtoon post latest", "CreationDate": "2019-8-21", "Commands": [ { "Command": "comment", "Target": "Open Webtoon and go to the edit episode page", "Value": "" }, { "Command": "open", "Target": "https://www.webtoons.com/en/", "Value": "" }, { "Command": "type", "Target": "id=emailId", "Value": "user@example.com" }, { "Command": "type", "Target": "id=password", "Value": "letmein" }, { "Command": "click", "Target": "link=Log In", "Value": "" }, { "Command": "clickAndWait", "Target": "css=a#btnLogIn", "Value": "" }, { "Command": "clickAndWait", "Target": "link=Dashboard", "Value": "" }, { "Command": "clickAndWait", "Target": "link=Edit Episode", "Value": "" }, { "Command": "comment", "Target": "If we have a PUBLISHED text...", "Value": "" }, { "Command": "verifyElementPresent", "Target": "css=#_listUl > li > a > span.subj > em.tx_published", "Value": "" }, { "Command": "if_v2", "Target": "${!lastcommandOK} == false", "Value": "" }, { "Command": "comment", "Target": "Click the page number after our current one and search again", "Value": "" }, { "Command": "label", "Target": "NextPageAndSearchAgain", "Value": "" }, { "Command": "clickAndWait", "Target": "css=#content > div.card_wrap.my > div.detail_body.episode > div > div > a[href=\"#\"] + a", "Value": "" }, { "Command": "comment", "Target": "Quick nested if: If PUBLISHED not there, next page and try again", "Value": "" }, { "Command": "verifyElementPresent", "Target": "css=#_listUl > li > a > span.subj > em.tx_published", "Value": "" }, { "Command": "if_v2", "Target": "${!lastcommandOK} == false", "Value": "" }, { "Command": "gotoLabel", "Target": "NextPageAndSearchAgain", "Value": "" }, { "Command": "end", "Target": "", "Value": "" }, { "Command": "comment", "Target": "End our if, we are now on a page with PUBLISHED", "Value": "" }, { "Command": "end", "Target": "", "Value": "" }, { "Command": "comment", "Target": "Failsafe: If we don't have a PUBLISH, we went too far", "Value": "" }, { "Command": "verifyElementPresent", "Target": "css=#_listUl > li > a > span.subj > button", "Value": "" }, { "Command": "if_v2", "Target": "${!lastcommandOK} == false", "Value": "" }, { "Command": "storeEval", "Target": "window.history.back()", "Value": "" }, { "Command": "end", "Target": "", "Value": "" }, { "Command": "comment", "Target": "Click the last green PUBLISH button", "Value": "" }, { "Command": "click", "Target": "xpath=//*[@id=\"_listUl\"]/li[descendant::button][last()]/a/span/button", "Value": "" }, { "Command": "click", "Target": "link=Yes", "Value": "" }, { "Command": "comment", "Target": "Log out", "Value": "" }, { "Command": "open", "Target": "https://www.webtoons.com/member/logout", "Value": "" } ] }