[BUG] User prompt text permanently lost when skill invocation fails (Desktop)

Resolved 💬 4 comments Opened Apr 15, 2026 by pyros-projects Closed Apr 18, 2026

Preflight Checklist

  • [x] I have searched existing issues and this hasn't been reported yet
  • [x] This is a single bug report
  • [x] I am using the latest version of Claude Code

What's Wrong?

When a user types a /slash-command followed by additional prompt text (e.g., /surface-first-development the textcompletion knows it tho) and the skill fails to load, the entire user input is replaced with a red error banner:

Unknown skill: surface-first-development

The original prompt text that was typed after the slash command is permanently lost. There is no way to recover, edit, or re-submit the message. The user's input is gone from the chat and from the input field.

What Should Happen?

When a skill fails to load:

  1. The error should be displayed without destroying the user's input
  2. The original prompt text should remain in the input field (or at minimum in the chat history) so the user can edit and resubmit
  3. Ideally, the failed /slash-command portion could be highlighted or stripped, leaving the rest of the prompt intact

Steps to Reproduce

  1. Have a plugin installed whose skills are visible in the Customize UI (autocomplete suggests them) but fail to load at runtime. This can happen when:
  • A plugin was installed from a git-sourced marketplace that doesn't load skills properly (observed on older versions)
  • A plugin has a loading error
  • Any other condition where the UI registers the skill but the runtime can't resolve it
  1. In the chat input, type a slash command from that plugin followed by additional text:

``
/surface-first-development the textcompletion knows it tho
``
Note: The autocomplete dropdown recognizes and suggests the skill name, so the user has no indication it won't work.

  1. Press Enter to submit.
  1. Result: The entire message is replaced with a red Unknown skill: surface-first-development banner. The additional text "the textcompletion knows it tho" is permanently gone — not in the chat, not in the input field, not recoverable.
  1. Expected: The error is shown but the original prompt text is preserved so the user can edit or resubmit.

Claude Model

Opus

Is this a regression?

I don't know

Claude Code Version

2.1.108 (Claude Code)

Platform

Anthropic API

Operating System

Windows

Terminal/Shell

Claude Code Desktop (native app)

Additional Information

See attached screenshot showing the behavior — autocomplete recognizes the skill, but after submission the prompt is replaced by the error banner.

This is particularly frustrating when the user has typed a long, detailed prompt after the slash command. The autocomplete suggesting the skill name creates a false sense of confidence that it will work, making the data loss unexpected.

Suggested fix: on skill invocation failure, preserve the user's input text and display the error as a non-destructive notification or inline warning rather than replacing the entire message.

Repro steps:

  • /any_skill_that_does_not_exist -> Claude crashes/doesn't answer

<img width="213" height="97" alt="Image" src="https://github.com/user-attachments/assets/3ca06449-c5d7-471e-8d5f-b029f2dae7b1" />

  • restart Claude Desktop - skill error msg + original prompt gone

<img width="161" height="88" alt="Image" src="https://github.com/user-attachments/assets/b25293b2-5252-4254-8016-743f6ae46594" />

View original on GitHub ↗

This issue has 4 comments on GitHub. Read the full discussion on GitHub ↗