Significant-Gravitas/AutoGPT · error · Error

Login failed

Error message

Login failed

What it means

NotFoundError raised by reject_transfer (and approve/execute share the pattern) when no TransferRequest row with the given id exists in the database. It is a not-found condition, not a permission or state error.

Source

Thrown at autogpt_platform/frontend/src/app/(no-navbar)/login/useLoginPage.ts:103

    setIsLoading(true);
    setIsLoggingIn(true);

    if (data.email.includes("@agpt.co")) {
      toast({
        title: "Please use Google SSO to login using an AutoGPT email.",
        variant: "default",
      });

      setIsLoading(false);
      setIsLoggingIn(false);
      return;
    }

    try {
      const result = await loginAction(data.email, data.password);

      if (!result.success) {
        throw new Error(result.error || "Login failed");
      }

      // Use full page navigation to ensure middleware processes the new auth cookies.
      // router.replace() does a soft navigation where the cookie store may not
      // immediately reflect cookies set by the server action, causing a blank page.
      // This matches the OAuth flow which also uses window.location.href.
      window.location.href = nextUrl || result.next || "/";
    } catch (error) {
      toast({
        title:
          error instanceof Error
            ? error.message
            : "Unexpected error during login",
        variant: "destructive",
      });

      setIsLoading(false);
      setIsLoggingIn(false);

View on GitHub (pinned to 9c8bb5550f)

Solutions

  1. Verify the transfer_id exists first (GET the transfer) and handle 404 by refreshing the list.
  2. Confirm the backend is pointing at the same database/environment where the transfer was created.
  3. Check the id for whitespace/truncation before sending.

Example fix

# before
await reject_transfer(tid, user_id, org_id)

# after
tr = await get_transfer(tid)  # raises NotFoundError with the same id in the message
await reject_transfer(tr.id, user_id, org_id)
Defensive patterns

Strategy: validation

Validate before calling

tr = await get_transfer(transfer_id)  # raises the same NotFoundError first
# proceed to reject only with a confirmed id

Try / catch

try:
    await reject_transfer(tid, user_id, org_id)
except NotFoundError:
    refresh_transfer_list()  # id no longer exists

Prevention

When it happens

Trigger: Calling reject (or approve/execute) with a transfer_id that was deleted, never existed, or contains a typo. Also occurs when the row is filtered by an environment mismatch (pointing at a different DB than the one that created the request).

Common situations: Stale transfer list in the frontend referencing a deleted request; copy-paste of an id between dev/staging environments; id truncation in URLs or logs.

Related errors


AI-assisted analysis of Significant-Gravitas/AutoGPT@9c8bb5550f (2026-08-14). Data as JSON: /api/errors/95b1fd5fe918f1a3. Report an issue: GitHub.