[BUG] Context of selected lines doesn't gets attached for some file paths
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?
In claude code's vs code extension , while using nextjs as a framework, we often use [slug] pattern for dynamic routes. For any new file created inside that folder , if I select some lines , they are not being reflected as lines being selected in claude code extension.I even confirmed this by asking the model if it can see any lines selected.To which , it replied a clear no .
<img width="1918" height="1023" alt="Image" src="https://github.com/user-attachments/assets/44eff21f-b2fa-4db0-92e0-b2a782444a34" />
What Should Happen?
Lines selected should be reflected and passed to claude code.
Error Messages/Logs
I have attached a screenshot for reference.
Steps to Reproduce
Create a dynamic folder in nextjs framework with [slug] pattern.
Create any new file inside it.
Add some text and try to select that text and pass to claude code.
Claude Model
Opus
Is this a regression?
I don't know
Last Working Version
_No response_
Claude Code Version
2.1.119
Platform
Anthropic API
Operating System
Windows
Terminal/Shell
VS Code integrated terminal
Additional Information
_No response_
This issue has 1 comment on GitHub. Read the full discussion on GitHub ↗