Where does the bug appear (feature/product)?
Cursor IDE
Describe the Bug
Bug Report
Where does the bug appear?
- Cursor IDE (desktop) — reproducible
- Same project / same Dart & Flutter extensions in VS Code work correctly (control case)
Describe the Bug
Using Flutter/Dart refactor “Wrap with…” (and related wrap actions) fails in Cursor with:
Actual command not found, wanted to execute _dart.applySnippetTextEdit /217 __vsc… undefined
The Dart extension activates successfully. The failure is in Cursor’s CommandsConverter when applying the code action command that Dart injects for LSP snippet TextEdits (_dart.applySnippetTextEdit). Lookup of the internal $ident returns undefined.
This is not an issue with the Dart extension itself: VS Code with the same extension version and dart.lspSnippetTextEdits: true (default) works.
Steps to Reproduce
- Open any Flutter/Dart project in Cursor
- Ensure extensions Dart and Flutter (Dart-Code) are installed and a
.dartfile is open - Place the cursor on a widget (e.g.
Text(...)/Image.network(...)) - Open Quick Fix / Refactor (
Cmd+.on macOS) - Choose Wrap with widget… or Wrap with Center / Column / etc.
- Observe the error; the edit is not applied
Expected Behavior
Widget is wrapped and the snippet placeholder (e.g. widget) is selected — same as in VS Code.
Actual Behavior
Code action fails. Extension Host log:
[error] Actual command not found, wanted to execute _dart.applySnippetTextEdit /217 __vscba8cd60a-cc68-4001-b9ad-50c7e79b898f undefined
Dart extension activation in the same session succeeds beforehand:
Extension activated success: Dart-Code.dart-code
Extension activated success: Dart-Code.flutter
Screenshots / Screen Recordings
N/A — error is from Extension Host (CommandsConverter#EXECUTE).
Operating System
macOS 26.5.2 (Build 25F84), Apple Silicon
Current Cursor Version
- Cursor: 3.14.27 (commit
047548b00c1a079373d74d00183f32510a4a41e0, arm64) - Dart extension: 3.140.0 (
Dart-Code.dart-code) - Flutter extension: 3.140.0 (
Dart-Code.flutter) - Flutter SDK: 3.44.6 / Dart 3.12.2
Additional Information / Technical notes
- Dart middleware rewrites snippet workspace edits from code actions into command
_dart.applySnippetTextEditso the editor can expand the snippet and place the cursor. - VS Code’s command converter keeps the
$identmapping; Cursor loses it (undefinedat the end of the error). - Workaround that restores Wrap with in Cursor (losing snippet cursor placement): set
"dart.lspSnippetTextEdits": false— not needed in VS Code. - Error originates from Cursor/VS Code fork path:
CommandsConverter#EXECUTE→Actual command not found, wanted to execute ${e[0]}
inextensionHostProcess.js.
Does this stop you from using Cursor?
- Yes — partially. Flutter refactor “Wrap with” is unusable without disabling snippet TextEdits (or switching to VS Code for those refactors).
Steps to Reproduce
- Open any Flutter/Dart project in Cursor (not VS Code).
- Confirm extensions Dart and Flutter (Dart-Code) are installed and enabled.
- Open a
.dartfile with a widget, e.g.Text('hello')orImage.network(...). - Place the caret on the widget name.
- Open Quick Fix / Refactor (
Cmd+.on macOS /Ctrl+.on Windows/Linux). - Choose Wrap with widget… (or Wrap with Center / Column / etc.).
- Observe the failure: edit is not applied; Extension Host shows
Actual command not found, wanted to execute _dart.applySnippetTextEdit … undefined.
Control: repeat steps 3–6 in VS Code with the same project and Dart extension → Wrap with works.
Operating System
MacOS
Version Information
Version Information
- Cursor: 3.14.27 (
047548b00c1a079373d74d00183f32510a4a41e0, arm64) - OS: macOS 26.5.2 (Build 25F84), Apple Silicon
- Dart extension: 3.140.0 (
Dart-Code.dart-code) - Flutter extension: 3.140.0 (
Dart-Code.flutter) - Flutter SDK: 3.44.6 (stable)
- Dart SDK: 3.12.2
Additional Information
This is a critical Flutter workflow issue. Wrap with (and related wrap/remove widget refactors) is one of the most frequently used actions when building Flutter UIs — we use it constantly while composing widget trees.
Losing it in Cursor forces either:
- manually rewriting wrappers by hand, or
- switching back to VS Code just for refactors, or
- disabling
dart.lspSnippetTextEdits(workaround that restores Wrap but loses snippet cursor placement).
Same project + same Dart/Flutter extension versions work correctly in VS Code, so this appears to be a Cursor-specific regression in how code-action commands (_dart.applySnippetTextEdit / CommandsConverter) are resolved.
Does this stop you from using Cursor
No - Cursor works, but with this issue



