From c78586926a53ea7221282a38f70528e56324b687 Mon Sep 17 00:00:00 2001 From: Matthew Jackson Date: Fri, 6 Mar 2026 21:45:41 -0800 Subject: [PATCH] Extend submit polling to ~30s for reCAPTCHA verification Invisible reCAPTCHA + server round-trip can take 10-30s. Increased from 6x2.5s (~15s) to 10x3s (~30s) polling window. Co-Authored-By: Claude Opus 4.6 --- lib/apply/generic.mjs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/apply/generic.mjs b/lib/apply/generic.mjs index 56e5c54..e3a3170 100644 --- a/lib/apply/generic.mjs +++ b/lib/apply/generic.mjs @@ -154,8 +154,8 @@ async function fillAndSubmit(page, job, formFiller, meta, opts) { // (invisible reCAPTCHA + server round-trip can take several seconds) const verifySelector = opts.verifySelector || 'form button[type="submit"]:not([disabled])'; let postSubmit = { hasSuccess: false, hasForm: true, validationErrors: [] }; - for (let wait = 0; wait < 6; wait++) { - await page.waitForTimeout(wait === 0 ? SUBMIT_WAIT : 2500); + for (let wait = 0; wait < 10; wait++) { + await page.waitForTimeout(wait === 0 ? SUBMIT_WAIT : 3000); postSubmit = await page.evaluate((vs) => { const text = (document.body.innerText || '').toLowerCase(); const errorEls = document.querySelectorAll('[class*="error"], [class*="invalid"], [role="alert"]');