我已经开发了一段时间的Flutter应用程序。自从最后一次更新以来,我一直收到这个消息:
在您的Flutter SDK中找不到Dart。请在终端中运行“flutter doctor”,然后在解决所有问题后重新加载项目。
我现在无法在VS Code中运行我的应用程序。当我在终端中运行flutter doctor
时,一切似乎都很正常。
[00:26:17] [General] [Info] Searching for SDKs...
[00:26:17] [General] [Info] Environment PATH:
[00:26:17] [General] [Info] C:\ProgramData\Oracle\Java\javapath
[00:26:17] [General] [Info] C:\Program Files (x86)\Intel\iCLS Client\
[00:26:17] [General] [Info] C:\Program Files\Intel\iCLS Client\
[00:26:17] [General] [Info] C:\Windows\system32
[00:26:17] [General] [Info] C:\Windows
[00:26:17] [General] [Info] C:\Windows\System32\Wbem
[00:26:17] [General] [Info] C:\Windows\System32\WindowsPowerShell\v1.0\
[00:26:17] [General] [Info] C:\Program Files\Intel\Intel(R) Management Engine Components\DAL
[00:26:17] [General] [Info] C:\Program Files (x86)\Intel\Intel(R) Management Engine Components\DAL
[00:26:17] [General] [Info] C:\Program Files\Intel\Intel(R) Management Engine Components\IPT
[00:26:17] [General] [Info] C:\Program Files (x86)\Intel\Intel(R) Management Engine Components\IPT
[00:26:17] [General] [Info] C:\Program Files\Intel\WiFi\bin\
[00:26:17] [General] [Info] C:\Program Files\Common Files\Intel\WirelessCommon\
[00:26:17] [General] [Info] C:\Program Files\Microsoft\Web Platform Installer\
[00:26:17] [General] [Info] c:\Program Files (x86)\Microsoft SQL Server\100\Tools\Binn\
[00:26:17] [General] [Info] c:\Program Files\Microsoft SQL Server\100\Tools\Binn\
[00:26:17] [General] [Info] c:\Program Files\Microsoft SQL Server\100\DTS\Binn\
[00:26:17] [General] [Info] C:\Program Files (x86)\NVIDIA Corporation\PhysX\Common
[00:26:17] [General] [Info] C:\MinGW\bin
[00:26:17] [General] [Info] C:\Program Files\Microsoft SQL Server\Client SDK\ODBC\130\Tools\Binn\
[00:26:17] [General] [Info] C:\Program Files (x86)\Microsoft SQL Server\140\Tools\Binn\
[00:26:17] [General] [Info] C:\Program Files\Microsoft SQL Server\140\Tools\Binn\
[00:26:17] [General] [Info] C:\Program Files\Microsoft SQL Server\140\DTS\Binn\
[00:26:17] [General] [Info] C:\Program Files (x86)\Microsoft SQL Server\150\DTS\Binn\
[00:26:17] [General] [Info] C:\Program Files\Git\cmd
[00:26:17] [General] [Info] C:\src\flutter\bin
[00:26:17] [General] [Info] C:\Users\yugiyuu\AppData\Local\Android\tools
[00:26:17] [General] [Info] C:\Users\yugiyuu\AppData\Local\Androidplatform-tools
[00:26:17] [General] [Info] C:\Users\yugiyuu\AppData\Local\Programs\Microsoft VS Code\bin
[00:26:17] [General] [Info] Found Flutter project at C:\Users\yugiyuu\Desktop\FindMeReal\FindMeReal:
Mobile? true
Web? false
Create Trigger? false
Flutter Repo? false
[00:26:17] [General] [Info] Searching for flutter.bat
[00:26:17] [General] [Info] Looking for flutter.bat in:
[00:26:17] [General] [Info] C:\Users\yugiyuu\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\flutter
[00:26:17] [General] [Info] C:\Users\yugiyuu\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\flutter\bin
[00:26:17] [General] [Info] C:\Users\yugiyuu\Desktop\FindMeReal\FindMeReal
[00:26:17] [General] [Info] C:\Users\yugiyuu\Desktop\FindMeReal\FindMeReal\bin
[00:26:17] [General] [Info] C:\src\flutter\bin\
[00:26:17] [General] [Info] C:\Users\yugiyuu\Desktop\FindMeReal\FindMeReal\.flutter
[00:26:17] [General] [Info] C:\Users\yugiyuu\Desktop\FindMeReal\FindMeReal\.flutter\bin
[00:26:17] [General] [Info] C:\Users\yugiyuu\Desktop\FindMeReal\FindMeReal\vendor\flutter
[00:26:17] [General] [Info] C:\Users\yugiyuu\Desktop\FindMeReal\FindMeReal\vendor\flutter\bin
[00:26:17] [General] [Info] C:\ProgramData\Oracle\Java\javapath
[00:26:17] [General] [Info] C:\ProgramData\Oracle\Java\javapath\bin
[00:26:17] [General] [Info] C:\Program Files (x86)\Intel\iCLS Client\
[00:26:17] [General] [Info] C:\Program Files (x86)\Intel\iCLS Client\bin
[00:26:17] [General] [Info] C:\Program Files\Intel\iCLS Client\
[00:26:17] [General] [Info] C:\Program Files\Intel\iCLS Client\bin
[00:26:17] [General] [Info] C:\Windows\system32
[00:26:17] [General] [Info] C:\Windows\system32\bin
[00:26:17] [General] [Info] C:\Windows
[00:26:17] [General] [Info] C:\Windows\bin
[00:26:17] [General] [Info] C:\Windows\System32\Wbem
[00:26:17] [General] [Info] C:\Windows\System32\Wbem\bin
[00:26:17] [General] [Info] C:\Windows\System32\WindowsPowerShell\v1.0\
[00:26:17] [General] [Info] C:\Windows\System32\WindowsPowerShell\v1.0\bin
[00:26:17] [General] [Info] C:\Program Files\Intel\Intel(R) Management Engine Components\DAL
[00:26:17] [General] [Info] C:\Program Files\Intel\Intel(R) Management Engine Components\DAL\bin
[00:26:17] [General] [Info] C:\Program Files (x86)\Intel\Intel(R) Management Engine Components\DAL
[00:26:17] [General] [Info] C:\Program Files (x86)\Intel\Intel(R) Management Engine Components\DAL\bin
[00:26:17] [General] [Info] C:\Program Files\Intel\Intel(R) Management Engine Components\IPT
[00:26:17] [General] [Info] C:\Program Files\Intel\Intel(R) Management Engine Components\IPT\bin
[00:26:17] [General] [Info] C:\Program Files (x86)\Intel\Intel(R) Management Engine Components\IPT
[00:26:17] [General] [Info] C:\Program Files (x86)\Intel\Intel(R) Management Engine Components\IPT\bin
[00:26:17] [General] [Info] C:\Program Files\Intel\WiFi\bin\
[00:26:17] [General] [Info] C:\Program Files\Common Files\Intel\WirelessCommon\
[00:26:17] [General] [Info] C:\Program Files\Common Files\Intel\WirelessCommon\bin
[00:26:17] [General] [Info] C:\Program Files\Microsoft\Web Platform Installer\
[00:26:17] [General] [Info] C:\Program Files\Microsoft\Web Platform Installer\bin
[00:26:17] [General] [Info] c:\Program Files (x86)\Microsoft SQL Server\100\Tools\Binn\
[00:26:17] [General] [Info] c:\Program Files (x86)\Microsoft SQL Server\100\Tools\Binn\bin
[00:26:17] [General] [Info] c:\Program Files\Microsoft SQL Server\100\Tools\Binn\
[00:26:17] [General] [Info] c:\Program Files\Microsoft SQL Server\100\Tools\Binn\bin
[00:26:17] [General] [Info] c:\Program Files\Microsoft SQL Server\100\DTS\Binn\
[00:26:17] [General] [Info] c:\Program Files\Microsoft SQL Server\100\DTS\Binn\bin
[00:26:17] [General] [Info] C:\Program Files (x86)\NVIDIA Corporation\PhysX\Common
[00:26:17] [General] [Info] C:\Program Files (x86)\NVIDIA Corporation\PhysX\Common\bin
[00:26:17] [General] [Info] C:\MinGW\bin
[00:26:17] [General] [Info] C:\Program Files\Microsoft SQL Server\Client SDK\ODBC\130\Tools\Binn\
[00:26:17] [General] [Info] C:\Program Files\Microsoft SQL Server\Client SDK\ODBC\130\Tools\Binn\bin
[00:26:17] [General] [Info] C:\Program Files (x86)\Microsoft SQL Server\140\Tools\Binn\
[00:26:17] [General] [Info] C:\Program Files (x86)\Microsoft SQL Server\140\Tools\Binn\bin
[00:26:17] [General] [Info] C:\Program Files\Microsoft SQL Server\140\Tools\Binn\
[00:26:17] [General] [Info] C:\Program Files\Microsoft SQL Server\140\Tools\Binn\bin
[00:26:17] [General] [Info] C:\Program Files\Microsoft SQL Server\140\DTS\Binn\
[00:26:17] [General] [Info] C:\Program Files\Microsoft SQL Server\140\DTS\Binn\bin
[00:26:17] [General] [Info] C:\Program Files (x86)\Microsoft SQL Server\150\DTS\Binn\
[00:26:17] [General] [Info] C:\Program Files (x86)\Microsoft SQL Server\150\DTS\Binn\bin
[00:26:17] [General] [Info] C:\Program Files\Git\cmd
[00:26:17] [General] [Info] C:\Program Files\Git\cmd\bin
[00:26:17] [General] [Info] C:\src\flutter\bin
[00:26:17] [General] [Info] C:\Users\yugiyuu\AppData\Local\Android\tools
[00:26:17] [General] [Info] C:\Users\yugiyuu\AppData\Local\Android\tools\bin
[00:26:17] [General] [Info] C:\Users\yugiyuu\AppData\Local\Androidplatform-tools
[00:26:17] [General] [Info] C:\Users\yugiyuu\AppData\Local\Androidplatform-tools\bin
[00:26:17] [General] [Info] C:\Users\yugiyuu\AppData\Local\Programs\Microsoft VS Code\bin
[00:26:17] [General] [Info] Found at:
[00:26:17] [General] [Info] C:\Users\yugiyuu\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\flutter\bin
[00:26:17] [General] [Info] C:\src\flutter\bin\
[00:26:17] [General] [Info] C:\src\flutter\bin
[00:26:17] [General] [Info] Candidate paths to be post-filtered:
[00:26:17] [General] [Info] C:\Users\yugiyuu\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\flutter
[00:26:17] [General] [Info] C:\src\flutter
[00:26:17] [General] [Info] C:\src\flutter
[00:26:17] [General] [Info] Found at C:\Users\yugiyuu\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\flutter
[00:26:17] [General] [Info] Returning SDK path C:\Users\yugiyuu\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\flutter for flutter.bat
[00:26:17] [General] [Info] Searching for dart.exe
[00:26:17] [General] [Info] Looking for dart.exe in:
[00:26:17] [General] [Info] C:\Users\yugiyuu\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\flutter\bin\cache\dart-sdk
[00:26:17] [General] [Info] C:\Users\yugiyuu\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\flutter\bin\cache\dart-sdk\bin
[00:26:17] [General] [Info] C:\ProgramData\Oracle\Java\javapath
[00:26:17] [General] [Info] C:\ProgramData\Oracle\Java\javapath\bin
[00:26:17] [General] [Info] C:\Program Files (x86)\Intel\iCLS Client\
[00:26:17] [General] [Info] C:\Program Files (x86)\Intel\iCLS Client\bin
[00:26:17] [General] [Info] C:\Program Files\Intel\iCLS Client\
[00:26:17] [General] [Info] C:\Program Files\Intel\iCLS Client\bin
[00:26:17] [General] [Info] C:\Windows\system32
[00:26:17] [General] [Info] C:\Windows\system32\bin
[00:26:17] [General] [Info] C:\Windows
[00:26:17] [General] [Info] C:\Windows\bin
[00:26:17] [General] [Info] C:\Windows\System32\Wbem
[00:26:17] [General] [Info] C:\Windows\System32\Wbem\bin
[00:26:17] [General] [Info] C:\Windows\System32\WindowsPowerShell\v1.0\
[00:26:17] [General] [Info] C:\Windows\System32\WindowsPowerShell\v1.0\bin
[00:26:17] [General] [Info] C:\Program Files\Intel\Intel(R) Management Engine Components\DAL
[00:26:17] [General] [Info] C:\Program Files\Intel\Intel(R) Management Engine Components\DAL\bin
[00:26:17] [General] [Info] C:\Program Files (x86)\Intel\Intel(R) Management Engine Components\DAL
[00:26:17] [General] [Info] C:\Program Files (x86)\Intel\Intel(R) Management Engine Components\DAL\bin
[00:26:17] [General] [Info] C:\Program Files\Intel\Intel(R) Management Engine Components\IPT
[00:26:17] [General] [Info] C:\Program Files\Intel\Intel(R) Management Engine Components\IPT\bin
[00:26:17] [General] [Info] C:\Program Files (x86)\Intel\Intel(R) Management Engine Components\IPT
[00:26:17] [General] [Info] C:\Program Files (x86)\Intel\Intel(R) Management Engine Components\IPT\bin
[00:26:17] [General] [Info] C:\Program Files\Intel\WiFi\bin\
[00:26:17] [General] [Info] C:\Program Files\Common Files\Intel\WirelessCommon\
[00:26:17] [General] [Info] C:\Program Files\Common Files\Intel\WirelessCommon\bin
[00:26:17] [General] [Info] C:\Program Files\Microsoft\Web Platform Installer\
[00:26:17] [General] [Info] C:\Program Files\Microsoft\Web Platform Installer\bin
[00:26:17] [General] [Info] c:\Program Files (x86)\Microsoft SQL Server\100\Tools\Binn\
[00:26:17] [General] [Info] c:\Program Files (x86)\Microsoft SQL Server\100\Tools\Binn\bin
[00:26:17] [General] [Info] c:\Program Files\Microsoft SQL Server\100\Tools\Binn\
[00:26:17] [General] [Info] c:\Program Files\Microsoft SQL Server\100\Tools\Binn\bin
[00:26:17] [General] [Info] c:\Program Files\Microsoft SQL Server\100\DTS\Binn\
[00:26:17] [General] [Info] c:\Program Files\Microsoft SQL Server\100\DTS\Binn\bin
[00:26:17] [General] [Info] C:\Program Files (x86)\NVIDIA Corporation\PhysX\Common
[00:26:17] [General] [Info] C:\Program Files (x86)\NVIDIA Corporation\PhysX\Common\bin
[00:26:17] [General] [Info] C:\MinGW\bin
[00:26:17] [General] [Info] C:\Program Files\Microsoft SQL Server\Client SDK\ODBC\130\Tools\Binn\
[00:26:17] [General] [Info] C:\Program Files\Microsoft SQL Server\Client SDK\ODBC\130\Tools\Binn\bin
[00:26:17] [General] [Info] C:\Program Files (x86)\Microsoft SQL Server\140\Tools\Binn\
[00:26:17] [General] [Info] C:\Program Files (x86)\Microsoft SQL Server\140\Tools\Binn\bin
[00:26:17] [General] [Info] C:\Program Files\Microsoft SQL Server\140\Tools\Binn\
[00:26:17] [General] [Info] C:\Program Files\Microsoft SQL Server\140\Tools\Binn\bin
[00:26:17] [General] [Info] C:\Program Files\Microsoft SQL Server\140\DTS\Binn\
[00:26:17] [General] [Info] C:\Program Files\Microsoft SQL Server\140\DTS\Binn\bin
[00:26:17] [General] [Info] C:\Program Files (x86)\Microsoft SQL Server\150\DTS\Binn\
[00:26:17] [General] [Info] C:\Program Files (x86)\Microsoft SQL Server\150\DTS\Binn\bin
[00:26:17] [General] [Info] C:\Program Files\Git\cmd
[00:26:17] [General] [Info] C:\Program Files\Git\cmd\bin
[00:26:17] [General] [Info] C:\src\flutter\bin
[00:26:17] [General] [Info] C:\Users\yugiyuu\AppData\Local\Android\tools
[00:26:17] [General] [Info] C:\Users\yugiyuu\AppData\Local\Android\tools\bin
[00:26:17] [General] [Info] C:\Users\yugiyuu\AppData\Local\Androidplatform-tools
[00:26:17] [General] [Info] C:\Users\yugiyuu\AppData\Local\Androidplatform-tools\bin
[00:26:17] [General] [Info] C:\Users\yugiyuu\AppData\Local\Programs\Microsoft VS Code\bin
[00:26:17] [General] [Info] C:\Users\yugiyuu\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\flutter\bin\cache\dart-sdk
[00:26:17] [General] [Info] C:\Users\yugiyuu\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\flutter\bin\cache\dart-sdk\bin
[00:26:17] [General] [Info] Found at:
[00:26:17] [General] [Info] C:\Users\yugiyuu\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\flutter\bin\cache\dart-sdk\bin
[00:26:17] [General] [Info] C:\Users\yugiyuu\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\flutter\bin\cache\dart-sdk\bin
[00:26:17] [General] [Info] Candidate paths to be post-filtered:
[00:26:17] [General] [Info] C:\Users\yugiyuu\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\flutter\bin\cache\dart-sdk
[00:26:17] [General] [Info] C:\Users\yugiyuu\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\flutter\bin\cache\dart-sdk
[00:26:17] [General] [Info] Returning SDK path undefined for dart.exe
这是我的日志。
Doctor summary (to see all details, run flutter doctor -v):
[√] Flutter (Channel stable, v1.17.0, on Microsoft Windows [Version 6.3.9600], locale tr-TR)
[√] Android toolchain - develop for Android devices (Android SDK version 29.0.2)
[√] Android Studio (version 3.6)
[√] VS Code (version 1.45.0)
[√] Connected device (1 available)
• No issues found!
这是我的flutter doctor
输出:
我该如何解决这个问题?
dart --version
时,您的输出是什么? - voidDart SDK
。 - void