-
Notifications
You must be signed in to change notification settings - Fork 86
Closed
Labels
P2A bug or feature request we're likely to work onA bug or feature request we're likely to work onpackage:webdevtriaged
Description
$ dart install webdev
$ webdev serve
Unhandled exception:
ProcessException: No such file or directory
Command: /Users/dacoharkes/Library/Application Support/Dart/install/app-bundles/webdev/hosted/3.7.2/bundle/bin/dart pub
#0 _ProcessImpl._runAndWait (dart:io-patch/process_patch.dart:519)
#1 _runNonInteractiveProcessSync (dart:io-patch/process_patch.dart:686)
#2 Process.runSync (dart:io-patch/process_patch.dart:79)
#3 _runPubDeps (package:webdev/src/pubspec.dart:50)
(Dart install is available in beta and dev releases.)
This is because it assumes it's running in JIT mode and that the running executable is dart.exe
.
webdev/webdev/lib/src/util.dart
Lines 30 to 38 in d2e5593
final String _sdkDir = (() { | |
// The Dart executable is in "/path/to/sdk/bin/dart", so two levels up is | |
// "/path/to/sdk". | |
final aboveExecutable = p.dirname(p.dirname(Platform.resolvedExecutable)); | |
assert(FileSystemEntity.isFileSync(p.join(aboveExecutable, 'version'))); | |
return aboveExecutable; | |
})(); | |
final String dartPath = p.join(_sdkDir, 'bin', 'dart'); |
However, with dart install
we get a self-contained application bundle in AOT mode.
We should find dart
or dart.exe
on PATH
with which dart
or where dart.exe
.
Metadata
Metadata
Assignees
Labels
P2A bug or feature request we're likely to work onA bug or feature request we're likely to work onpackage:webdevtriaged