moelhewehy7 · GitHub

Issue Type

Bug

Summary

VS Code shows ENOTDIR errors and Run/F5 does not work, while running from terminal works.

Error

ENOTDIR: not a directory, stat '/Users/al-almiyaal-hura/FlutterApps/manasa/lib/main.dart/pubspec.yaml'

What I expected

F5 / Run button should launch Flutter app.

What happens

Terminal commands work (flutter run), but VS Code Run/F5 fails.

Environment

  • OS: macOS
  • VS Code: (Help > About, paste version)
  • Flutter extension: (paste version)
  • Dart extension: (paste version)

Repro steps

  1. Open Flutter project.
  2. Press F5 or click Run button.
  3. VS Code fails with ENOTDIR and app does not launch.

Notes

I previously changed many VS Code paths/settings and did a reset, but issue still persists globally.

Read the original on github.com ↗