`ide_opened_file` context not updating for files in folders with Svelte optional parameter syntax

Resolved 💬 3 comments Opened Dec 12, 2025 by JackNeto Closed Dec 16, 2025

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?

The ide_opened_file context in Claude Code does not update when opening files inside folders that use Svelte optional parameter syntax with double square brackets (e.g., [[param_name]]).

The ide_opened_file context remains stuck on the previously opened file and does not update when switching to files in the [[job_post_id]] folder.

What Should Happen?

When opening a file in src/routes/sourcing/[[job_post_id]]/+page.svelte, the ide_opened_file context should update to reflect this file path.

Error Messages/Logs

Steps to Reproduce

  1. Open a Svelte project that has a route folder using optional parameter syntax: src/routes/sourcing/[[job_post_id]]/
  2. Open any file in a different folder (e.g., src/routes/admin/+page.svelte)
  3. Verify that Claude Code receives the correct ide_opened_file context
  4. Open a file inside the bracketed folder (e.g., src/routes/sourcing/[[job_post_id]]/+page.svelte)
  5. Observe that Claude Code's ide_opened_file context does not update - it shows the previously opened file instead

Claude Model

None

Is this a regression?

I don't know

Last Working Version

_No response_

Claude Code Version

2.0.28 (Claude Code)

Platform

Other

Operating System

macOS

Terminal/Shell

Terminal.app (macOS)

Additional Information

  • This issue is specific to folders with square brackets in the path
  • Opening files in other folders works correctly (e.g., src/routes/admin/+page.svelte updates context properly)
  • The single and double square brackets [[param_name]] are valid Svelte syntax for optional route parameters

View original on GitHub ↗

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