[BUG] `!history` command fails with "fc:1: no such event: 1" error

Resolved 💬 3 comments Opened Oct 22, 2025 by unknown10111 Closed Jan 8, 2026

Preflight Checklist

  • [x] I have searched existing issues and this hasn't been reported yet
  • [x] This is a single bug report (please file separate reports for different bugs)
  • [x] I am using the latest version of Claude Code

What's Wrong?

Environment

Platform: Anthropic API
Claude CLI version: 2.0.24 (Claude Code)
Operating System: macOS 26.0.1 (25A362)
Terminal: cluade code

Start Claude Code session with claude command
Run a few commands (e.g., ls, pwd, git status)
Try to view history by typing !history
Observe the error message

Expected Behavior
The command should either:

Display the shell command history from the current Claude Code session
Provide a clear error message explaining that !history is not supported and suggest alternative commands

What Should Happen?

Bug Description
When attempting to run !history command in Claude Code session, it fails with an error message (eval):fc:1: no such event: 1 instead of showing command history.
Steps to Reproduce

Error Messages/Logs

Steps to Reproduce

Steps to Reproduce

  1. Start Claude Code session with claude command
  2. Run a few commands (e.g., ls, pwd, git status)
  3. Try to view history by typing !history
  4. Observe the error message

Claude Model

None

Is this a regression?

I don't know

Last Working Version

_No response_

Claude Code Version

2.0.24

Platform

Anthropic API

Operating System

macOS

Terminal/Shell

Terminal.app (macOS)

Additional Information

_No response_

View original on GitHub ↗

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