【发布时间】:2019-08-09 16:22:58
【问题描述】:
Error: Error when reading 'bin/main.dart': The system cannot find the path specified.
我使用的是 Windows 10,当我调试代码时,VSCode 会显示上述结果,这是我曾经在 VSCode 中使用终端的一件事,flutter run 模拟器显示应用程序,但它没有显示热重载,并且其他选项,终端显示可能需要很长时间
这些是输出
Error: Error when reading 'bin/main.dart': The system cannot find the
path specified. Ignoring error posting over WebSocket. Bad state:
StreamSink is closed #0 _StreamSinkImpl.add
(dart:_http/http_impl.dart:536:7) #1 _WebSocketImpl.add
(dart:_http/websocket_impl.dart:1213:11) #2 WebSocketClient.post
(dart:vmservice_io/server.dart:78:18) #3 _RootZone.runUnary
(dart:async/zone.dart:1379:54) #4 _FutureListener.handleValue
(dart:async/future_impl.dart:126:18) #5
Future._propagateToListeners.handleValueCallback
(dart:async/future_impl.dart:639:45) #6 Future._propagateToListeners
(dart:async/future_impl.dart:668:32)
【问题讨论】:
-
听起来VSCode无法将你的项目识别为Flutter项目。你安装了 Flutter 插件吗?您是否使用 VSCode 创建了项目?
标签: websocket visual-studio-code flutter