Fission-AI/OpenSpec · error · StoreError

workset_launch_failed

workset_launch_failed

Error message

error.message

What it means

Catch-and-annotate wrapper in workset open: launchOpenerCommand threw (the external tool failed to start) and the message rethrows with fix context, e.g. a pasteable alternative opener when one is installed.

Solutions

  1. Follow the fix hint in the message (often an alternative installed tool)
  2. Verify the opener's command is installed and runnable on PATH
Defensive patterns

Strategy: try-catch

When it happens

Trigger: Thrown at src/commands/workset.ts:473 when the library encounters an invalid state.

Common situations: See trigger scenarios.


AI-assisted analysis of Fission-AI/OpenSpec@6926ccb18a (2026-08-25). Data as JSON: /api/errors/368439259759912c. Report an issue: GitHub.

Appendix: source

Thrown at src/commands/workset.ts:473

      } else {
        console.log(
          `Handing this terminal to ${opener.label} for '${name}' (the session ends when you exit).`
        );
      }

      let result: LaunchResult;
      try {
        result = await launchOpenerCommand(launch);
      } catch (error) {
        // Make the launch-failure fix pasteable when an alternative is
        // installed (the launcher itself does not know the table).
        if (
          error instanceof StoreError &&
          error.diagnostic.code === 'workset_launch_failed'
        ) {
          const alternative = firstInstalledAlternative(table, opener.id);
          if (alternative !== null) {
            throw new StoreError(error.message, 'workset_launch_failed', {
              target: 'workset.tool',
              fix: `Run: openspec workset open ${name} --tool ${alternative}`,
            });
          }
        }
        throw error;
      }

      const exitCode = exitCodeForLaunch(result);
      if (exitCode !== 0) {
        process.exitCode = exitCode;
      }
    } catch (error) {
      emitFailure(options.json, { status: [] }, error, 'workset_error');

      // Never strand the user: once the derived file is regenerated,
      // every failure (except a prompt cancellation) carries the
      // manual route - the file path plus the members it contains.

View on GitHub (pinned to 6926ccb18a)