MichaelRFairhurst / dust

A code-coverage guided fuzz tester for Dart
BSD 3-Clause "New" or "Revised" License
5 stars 2 forks source link

observatory is not starting (dart 2.13) #1

Open n0npax opened 3 years ago

n0npax commented 3 years ago

Hi,

Seems dust is not working well with null safety and the newest dart.

dart run bin/dust.dart example/crash_on_bad.dart 
Unhandled exception:
Observatory did not start on 7575
output:

#0      VmController._startProcess (package:dust/src/vm_controller.dart:268:7)
<asynchronous suspension>
#1      VmController.prestart (package:dust/src/vm_controller.dart:69:5)
<asynchronous suspension>
#2      Future.wait.<anonymous closure> (dart:async/future.dart)
<asynchronous suspension>
#3      Cli.run (package:dust/src/cli.dart:199:7)
<asynchronous suspension>
#4      main (file:///tmp/dust/bin/dust.dart:8:3)
<asynchronous suspension>
dart --version
Dart SDK version: 2.13.4 (stable) (Unknown timestamp) on "linux_x64"
clincoln8 commented 2 years ago

Was this ever resolved? I am having the same issue running on M1 Mac.

clincoln8 commented 2 years ago

The issue is caused by an outdated path in lib/src/vm_controller.dart to '.pub-cache/global_packages/dust/bin/controller.dart.snapshot.dart2'.

The current controller snapshot in pub_cache is called controller.dart-2.16.2.snapshot therefore to resolve this run

cp ~/.pub-cache/global_packages/dust/bin/controller.dart-2.16.2.snapshot ~/.pub-cache/global_packages/dust/bin/controller.dart.snapshot.dart2

to make the hardcoded path point to a valid controller snapshot.

n0npax commented 2 years ago

Awesome, Thank you for the hint. It works!