今天,当 vs 代码打开时,我在稳定通道上将颤振升级到 v 1.17.0,并且在我的项目中的 vs 代码上打开了一些选项卡。颤振更新完成后,vs 代码和 Android Studio 突然在我项目的 70% 的 .dart 文件中显示“URI 的目标不存在:”错误,即使这些文件位于主目录文件夹中。
首先我重新启动了 vs 代码(或 Android Studio),但出现了同样的错误。之后我尝试了这些命令,但错误仍然存在:
flutter clean
flutter packages upgrade
flutter packages get
这是颤振医生 -vv 的输出:
[ +24 ms] executing: [D:\SourceFiles\flutter/] git -c log.showSignature=false log -n 1 --pretty=format:%H
[ +61 ms] Exit code 0 from: git -c log.showSignature=false log -n 1 --pretty=format:%H
[ ] e6b34c2b5c96bb95325269a29a84e83ed8909b5f
[ ] executing: [D:\SourceFiles\flutter/] git tag --contains HEAD
[ +269 ms] Exit code 0 from: git tag --contains HEAD
[ +1 ms] 1.17.0
1.17.0-3.4.pre
[ +10 ms] executing: [D:\SourceFiles\flutter/] git rev-parse --abbrev-ref --symbolic @{u}
[ +36 ms] Exit code 0 from: git rev-parse --abbrev-ref --symbolic @{u}
[ ] origin/stable
[ ] executing: [D:\SourceFiles\flutter/] git ls-remote --get-url origin
[ +34 ms] Exit code 0 from: git ls-remote --get-url origin
[ ] https://github.com/flutter/flutter.git
[ +91 ms] executing: [D:\SourceFiles\flutter/] git rev-parse --abbrev-ref HEAD
[ +38 ms] Exit code 0 from: git rev-parse --abbrev-ref HEAD
[ +1 ms] stable
[ +51 ms] Artifact Instance of 'AndroidMavenArtifacts' is not required, skipping update.
[ ] Artifact Instance of 'AndroidGenSnapshotArtifacts' is not required, skipping update.
[ ] Artifact Instance of 'AndroidInternalBuildArtifacts' is not required, skipping update.
[ ] Artifact Instance of 'IOSEngineArtifacts' is not required, skipping update.
[ ] Artifact Instance of 'FlutterWebSdk' is not required, skipping update.
[ +3 ms] Artifact Instance of 'WindowsEngineArtifacts' is not required, skipping update.
[ +21 ms] Artifact Instance of 'MacOSEngineArtifacts' is not required, skipping update.
[ +7 ms] Artifact Instance of 'LinuxEngineArtifacts' is not required, skipping update.
[ +1 ms] Artifact Instance of 'LinuxFuchsiaSDKArtifacts' is not required, skipping update.
[ +1 ms] Artifact Instance of 'MacOSFuchsiaSDKArtifacts' is not required, skipping update.
[ ] Artifact Instance of 'FlutterRunnerSDKArtifacts' is not required, skipping update.
[ +13 ms] Artifact Instance of 'FlutterRunnerDebugSymbols' is not required, skipping update.
[ +29 ms] Artifact Instance of 'MaterialFonts' is not required, skipping update.
[ ] Artifact Instance of 'GradleWrapper' is not required, skipping update.
[ ] Artifact Instance of 'AndroidMavenArtifacts' is not required, skipping update.
[ +11 ms] Artifact Instance of 'AndroidInternalBuildArtifacts' is not required, skipping update.
[ +6 ms] Artifact Instance of 'IOSEngineArtifacts' is not required, skipping update.
[ ] Artifact Instance of 'FlutterWebSdk' is not required, skipping update.
[ ] Artifact Instance of 'FlutterSdk' is not required, skipping update.
[ ] Artifact Instance of 'WindowsEngineArtifacts' is not required, skipping update.
[ ] Artifact Instance of 'MacOSEngineArtifacts' is not required, skipping update.
[ ] Artifact Instance of 'LinuxEngineArtifacts' is not required, skipping update.
[ ] Artifact Instance of 'LinuxFuchsiaSDKArtifacts' is not required, skipping update.
[ ] Artifact Instance of 'MacOSFuchsiaSDKArtifacts' is not required, skipping update.
[ ] Artifact Instance of 'FlutterRunnerSDKArtifacts' is not required, skipping update.
[ +13 ms] Artifact Instance of 'FlutterRunnerDebugSymbols' is not required, skipping update.
[ +1 ms] Artifact Instance of 'IosUsbArtifacts' is not required, skipping update.
[ ] Artifact Instance of 'IosUsbArtifacts' is not required, skipping update.
[ ] Artifact Instance of 'IosUsbArtifacts' is not required, skipping update.
[ ] Artifact Instance of 'IosUsbArtifacts' is not required, skipping update.
[ ] Artifact Instance of 'IosUsbArtifacts' is not required, skipping update.
[ +2 ms] Artifact Instance of 'FontSubsetArtifacts' is not required, skipping update.
[ +35 ms] executing: [D:\SourceFiles\flutter/] git rev-parse --abbrev-ref HEAD
[ +34 ms] Exit code 0 from: git rev-parse --abbrev-ref HEAD
[ ] stable
[ ] Skipping request to fetchTags - on well known channel stable.
[ ] executing: [D:\SourceFiles\flutter/] git tag --contains HEAD
[ +308 ms] Exit code 0 from: git tag --contains HEAD
[ +1 ms] 1.17.0
1.17.0-3.4.pre
[ +4 ms] Doctor summary (to see all details, run flutter doctor -v):
[ +18 ms] executing: C:\Program Files\Android\Android Studio\jre\bin\java -version
[ +121 ms] Exit code 0 from: C:\Program Files\Android\Android Studio\jre\bin\java -version
[ ] openjdk version "1.8.0_202-release"
OpenJDK Runtime Environment (build 1.8.0_202-release-1483-b03)
OpenJDK 64-Bit Server VM (build 25.202-b03, mixed mode)
[ +31 ms] executing: C:\Program Files\Android\Android Studio\jre\bin\java -version
[ +89 ms] Exit code 0 from: C:\Program Files\Android\Android Studio\jre\bin\java -version
[ ] openjdk version "1.8.0_202-release"
OpenJDK Runtime Environment (build 1.8.0_202-release-1483-b03)
OpenJDK 64-Bit Server VM (build 25.202-b03, mixed mode)
[ +9 ms] executing: [D:\SourceFiles\flutter/] git -c log.showSignature=false log -n 1 --pretty=format:%ar
[ +47 ms] Exit code 0 from: git -c log.showSignature=false log -n 1 --pretty=format:%ar
[ ] 10 days ago
[ +51 ms] java -version
[ +146 ms] executing: D:\SourceFiles\sdk\platform-tools\adb.exe devices -l
[ +19 ms] [√] Flutter (Channel stable, v1.17.0, on Microsoft Windows [Version 10.0.18362.418], locale en-US)
\[ +73 ms] List of devices attached
[ +8 ms] executing: D:\SourceFiles\sdk\platform-tools\adb.exe devices -l
|[ +62 ms] List of devices attached
[ +155 ms] executing: D:\SourceFiles\sdk\tools\bin\sdkmanager --licenses
[+1872 ms] [!] Android toolchain - develop for Android devices (Android SDK version 29.0.2)
[ +1 ms] X Android license status unknown.
[ +1 ms] Try re-installing or updating your Android SDK Manager.
[ ] See https://developer.android.com/studio/#downloads or visit visit https://flutter.dev/docs/get-started/install/windows#android-setup for detailed instructions.
[ +24 ms] [√] Android Studio (version 3.5)
[ +5 ms] [√] VS Code, 32-bit edition
[ +4 ms] [√] VS Code, 64-bit edition (version 1.44.2)
[ +12 ms] [!] Connected device
[ ] ! No devices available
[ ] ! Doctor found issues in 2 categories.
[ +9 ms] "flutter doctor" took 3,376ms.
任何想法?