different-ai/openwork · error
OpenWork server cannot remove skills for this workspace.
Error message
OpenWork server cannot remove skills for this workspace.
What it means
When removing a skill, the store deletes it through the OpenWork server if the workspace has an OpenWork target (server enabled + client + workspace id available). If a target exists but this code path cannot use it (missing openworkClient/openworkWorkspaceId, or the target workspace isn't server-managed), it throws this error instead of attempting a local delete that would not actually remove a server-backed skill.
Source
Thrown at apps/app/src/react-app/domains/settings/state/extensions-store.ts:696
};
const deleteWorkspaceSkill = async (name: string) => {
const isRemoteWorkspace = options.workspaceType() === "remote";
const isLocalWorkspace = options.workspaceType() === "local";
const root = options.selectedWorkspaceRoot().trim();
const { openworkSnapshot, openworkClient, openworkWorkspaceId, hasOpenworkTarget } =
await resolveWorkspaceServerTarget();
const canUseOpenworkServer =
hasOpenworkTarget &&
openworkSnapshot.openworkServerCapabilities?.skills?.write !== false;
if (canUseOpenworkServer && openworkClient && openworkWorkspaceId) {
await openworkClient.deleteSkill(openworkWorkspaceId, name);
return;
}
if (hasOpenworkTarget) {
throw new Error("OpenWork server cannot remove skills for this workspace.");
}
if (isRemoteWorkspace) {
throw new Error("OpenWork server unavailable. Connect to remove skills.");
}
if (!isDesktopRuntime()) {
throw new Error(t("skills.desktop_required"));
}
if (!isLocalWorkspace || !root) {
throw new Error(t("skills.pick_workspace_first"));
}
const result = (await uninstallSkillCommand(root, name)) as { ok: boolean; stderr?: string; stdout?: string };
if (!result.ok) {
throw new Error(result.stderr || result.stdout || t("skills.uninstall_failed"));
}View on GitHub (pinned to 2b7df46e8a)
Solutions
- Connect/sign in to the OpenWork server so openworkClient and openworkWorkspaceId resolve, then retry the delete.
- Verify the workspace id is still valid on the server; re-sync workspace state.
- If the skill is server-managed by policy, remove it via the Den/server admin surface instead.
- Restart the app to rebuild the client/session if state appears stale.
Example fix
// before
if (hasOpenworkTarget) {
throw new Error("OpenWork server cannot remove skills for this workspace.");
}
// after
if (hasOpenworkTarget) {
const connected = await ensureServerConnected();
if (connected && openworkWorkspaceId) {
await openworkClient.deleteSkill(openworkWorkspaceId, name);
return;
}
throw new Error("OpenWork server cannot remove skills for this workspace.");
} Defensive patterns
Strategy: validation
Validate before calling
if (hasOpenworkTarget && !(canUseOpenworkServer && openworkClient && openworkWorkspaceId)) {
// reconnect/refresh server session before offering skill delete
} Type guard
function canDeleteOnServer(s: { openworkClient?: unknown; openworkWorkspaceId?: string }): s is { openworkClient: NonNullable<unknown>; openworkWorkspaceId: string } {
return s.openworkClient != null && typeof s.openworkWorkspaceId === "string" && s.openworkWorkspaceId.length > 0;
} Try / catch
try {
await removeSkill(name);
} catch (err) {
if (err.message.includes("cannot remove skills")) await reconnectServerAndRetry(() => removeSkill(name));
else throw err;
} Prevention
- Refresh server session/workspace id whenever the workspace config changes
- Hide skill-delete actions for server-managed workspaces the user cannot modify
- Rebuild the openwork client after sign-out/sign-in instead of reusing a stale one
When it happens
Trigger: Deleting a skill from a workspace whose config declares an OpenWork server target while openworkClient/openworkWorkspaceId are not resolvable, or when canUseOpenworkServer is false despite hasOpenworkTarget being true.
Common situations: Workspace config lists cloud imports/skills but the app never established the server session; workspace id changed on the server; stale client after sign-out; org-managed workspace where the local user cannot delete.
Related errors
- OpenWork server unavailable. Connect to remove skills.
- Failed to delete skill (${response.status}).
- OpenWork server cannot read MCP config for this workspace.
- Cannot create a task without a selected workspace.
- Workspace path is unavailable; attachments could not be copi
AI-assisted analysis of different-ai/openwork@2b7df46e8a (2026-09-01).
Data as JSON: /api/errors/97971cad1c4ffcc3.
Report an issue: GitHub.