jackwener/OpenCLI · error · CommandExecutionError

Nothing changed. Open the tweet in the browser and retry.

Error message

Nothing changed. Open the tweet in the browser and retry.

What it means

When the in-page unretweet script returns `ok: false` without `unconfirmed`, this CommandExecutionError is thrown with the page's failure message plus the hint 'Nothing changed. Open the tweet in the browser and retry.' It means the flow failed deterministically before the confirm click — the retweet is guaranteed to be untouched.

Source

Thrown at clis/twitter/unretweet.js:91

            await new Promise(r => setTimeout(r, 1000));

            // Verify success by checking if the 'retweet' button reappeared
            const verifyArticle = findTargetArticle() || targetArticle;
            const verifyBtn = verifyArticle?.querySelector('[data-testid="retweet"]');
            if (verifyBtn) {
                return { ok: true, message: 'Tweet successfully unretweeted.' };
            } else {
                return { ok: false, unconfirmed: true, message: 'Unretweet action was initiated but UI did not update as expected.' };
            }
        } catch (e) {
            return { ok: false, unconfirmed: writeStarted, message: e.toString() };
        }
    })()`);
        if (result.unconfirmed) {
            throw new TimeoutError('twitter unretweet confirmation', 1, `${result.message} Check the tweet before retrying; the removal may already have succeeded.`);
        }
        if (!result.ok) {
            throw new CommandExecutionError(result.message, 'Nothing changed. Open the tweet in the browser and retry.');
        }
        await page.wait(2);
        return [{
                status: 'success',
                message: result.message
            }];
    }
});

View on GitHub (pinned to 49907e53dc)

Solutions

  1. Open the tweet in the opencli browser, verify login and that the retweet menu works, then re-run `opencli twitter unretweet <url>`.
  2. Re-authenticate x.com if action buttons are missing due to being logged out.
  3. Confirm the tweet still exists and the URL is correct.
  4. If the confirm item never appears, check for X.com data-testid changes around `unretweetConfirm` and update selectors.

Example fix

// before
opencli twitter unretweet https://x.com/user/status/123   // logged out, no Unretweet button
// after
opencli browser login x.com
opencli twitter unretweet https://x.com/user/status/123
Defensive patterns

Strategy: validation

Validate before calling

// pre-check login state so the Unretweet button exists
const loggedIn = await page.evaluate(`!!document.querySelector('[data-testid="AppTabBar_Profile_Link"]')`);
if (!loggedIn) throw new Error('Log into x.com before unretweeting');

Type guard

function isDeterministicUnretweetFailure(e) {
  return e instanceof CommandExecutionError && /Nothing changed/.test(String(e.hint || e.message));
}

Try / catch

try {
  await cli.run(['twitter', 'unretweet', tweetUrl]);
} catch (e) {
  if (isDeterministicUnretweetFailure(e)) {
    await ensureXLogin();
    await cli.run(['twitter', 'unretweet', tweetUrl]);
  } else throw e;
}

Prevention

When it happens

Trigger: The Unretweet button was not found after the 10s poll on the target article (usually logged out); the confirm menu item `[data-testid="unretweetConfirm"]` never appeared within 5s ('Unretweet menu opened but the confirm option did not appear'); any pre-write in-page exception.

Common situations: Expired x.com session so action buttons are hidden; deleted/protected tweet; tweet deleted mid-flow; rate limiting or A/B DOM changes removing the confirm testid.

Related errors


AI-assisted analysis of jackwener/OpenCLI@49907e53dc (2026-08-29). Data as JSON: /api/errors/1f033d7c7e5c5ed5. Report an issue: GitHub.