johnpryan / letsvote

153 stars 46 forks source link

Unhandled exception: Unsupported operation: Cannot extract a file path from a http URI #4

Open nailgilaziev opened 6 years ago

nailgilaziev commented 6 years ago

when do pub run bin/server.dart this occurs:

Unhandled exception:
Unsupported operation: Cannot extract a file path from a http URI
#0      _SimpleUri.toFilePath (dart:core/uri.dart:4561)
#1      main (http://localhost:55280/server.dart:17:46)
#2      _startIsolate.<anonymous closure> (dart:isolate-patch/dart:isolate/isolate_patch.dart:277)
#3      _RawReceivePortImpl._handleMessage (dart:isolate-patch/dart:isolate/isolate_patch.dart:165)

what I need to fix, who can help?

johnpryan commented 6 years ago

I think a workaround can be to just run the script using the dart command:

dart bin/server.dart
johnpryan commented 6 years ago

Reopening to find a better way to deal with pub's Platform.script:

http://localhost:54239/server.dart