[BUG] File paths treated like slash commands e.g. /login

Resolved 💬 3 comments Opened Oct 6, 2025 by djf1982 Closed Jan 9, 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?

When you reference a file-path that is also a slash command, Claude Code executes the command, ignoring the context.

e.g. /login, this is a common file-path but is also a claude slash command

What Should Happen?

Understand the context and only execute the slash command if that was the desired action

Error Messages/Logs

Steps to Reproduce

When you reference a file-path that is also a slash command, Claude Code executes the command, ignoring the context.

e.g. /login, this is a common file-path but is also a claude slash command

Claude Model

Sonnet (default)

Is this a regression?

I don't know

Last Working Version

_No response_

Claude Code Version

2.0.1 (Claude Code)

Platform

Anthropic API

Operating System

macOS

Terminal/Shell

VS Code integrated terminal

Additional Information

_No response_

View original on GitHub ↗

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