paperclipai/paperclip · warning

Could not open your browser automatically. Open this URL man

Error message

Could not open your browser automatically. Open this URL manually:
${companyUrl}

What it means

After a successful company import, the CLI offers to open the imported company's dashboard URL. openUrl(companyUrl) resolves false when no browser opener could be spawned (xdg-open/open/start missing or failing), so the CLI falls back to printing the URL for manual opening. The import itself already succeeded.

Source

Thrown at cli/src/commands/client/company.ts:1903

            printCompanyImportView(
              "Import Result",
              renderCompanyImportResult(imported, {
                targetLabel,
                companyUrl,
                infoMessages: adapterMessages,
              }),
              { interactive: interactiveView },
            );
            if (interactiveView && companyUrl) {
              const openImportedCompany = await p.confirm({
                message: "Open the imported company in your browser?",
                initialValue: true,
              });
              if (!p.isCancel(openImportedCompany) && openImportedCompany) {
                if (await openUrl(companyUrl)) {
                  p.log.info(`Opened ${companyUrl}`);
                } else {
                  p.log.warn(`Could not open your browser automatically. Open this URL manually:\n${companyUrl}`);
                }
              }
            }
          }
        } catch (err) {
          handleCommandError(err);
        }
      }),
  );

  addCommonClientOptions(
    company
      .command("delete")
      .description("Delete a company by ID or shortname/prefix (destructive)")
      .argument("<selector>", "Company ID or issue prefix (for example PAP)")
      .option(
        "--by <mode>",
        "Selector mode: auto | id | prefix",

View on GitHub (pinned to 120ae5428f)

Solutions

  1. Copy the printed URL and open it manually — nothing else is needed.
  2. Set the BROWSER environment variable (e.g. export BROWSER='wslview "%s"' on WSL, or 'firefox %s').
  3. On Linux install xdg-utils so xdg-open exists.
  4. Over SSH, forward the port (ssh -L 3100:localhost:3100) and open the localhost URL locally.
Defensive patterns

Strategy: fallback

Validate before calling

import { which } from "shelljs"; // or: command -v xdg-open
const hasOpener = process.platform === "darwin" || process.platform === "win32" || Boolean(which("xdg-open"));

Prevention

When it happens

Trigger: Interactive import (interactiveView true), companyUrl built from the imported company's issuePrefix, user confirms 'Open the imported company in your browser?', and openUrl returns false — typical over SSH, in containers, or on Linux without xdg-utils.

Common situations: Running the CLI over SSH with no local display; minimal container images without xdg-open; WSL without a Windows browser association; $BROWSER unset or pointing at a broken command.

Related errors


AI-assisted analysis of paperclipai/paperclip@120ae5428f (2026-08-18). Data as JSON: /api/errors/f055db01afe33e87. Report an issue: GitHub.