Flutter看起来很有希望,但偶尔我被卡住了。在这种情况下,错误说明:
package:async/src/typed/stream.dart': error: line 56: class 'TypeSafeStream' overrides method 'firstWhere' of super class or interface 'Stream' with incompatible parameters
我正在使用以下应该有效的代码:
new NetworkImage(googleSignIn.currentUser.photoUrl)
fluttor医生输出:
[✓] Flutter (on Mac OS X 10.13.4 17E139j, locale nl-NL, channel dev)
• Flutter version 0.1.2 at /Users/johngorter/Desktop/flutter/flutter
• Framework revision 8a65872ef9 (6 days ago), 2018-02-13 23:32:28 -0800
• Engine revision 05c5f817eb
• Tools Dart version 2.0.0-dev.22.0
• Engine Dart version 2.0.0-edge.3c4dccbd46f152be9e1b6ca95c57357e8e48057c
[✓] Android toolchain - develop for Android devices (Android SDK 26.0.2)
• Android SDK at /Users/johngorter/Library/Android/sdk
• Android NDK at /Users/johngorter/Library/Android/sdk/ndk-bundle
• Platform android-27, build-tools 26.0.2
• Java binary at: /Applications/Android Studio.app/Contents/jre/jdk/Contents/Home/bin/java
• Java version OpenJDK Runtime Environment (build 1.8.0_112-release-b06)
[!] iOS toolchain - develop for iOS devices (Xcode 9.2)
• Xcode at /Applications/Xcode.app/Contents/Developer
• Xcode 9.2, Build version 9C40b
✗ libimobiledevice and ideviceinstaller are not installed. To install, run:
brew install --HEAD libimobiledevice
brew install ideviceinstaller
✗ ios-deploy not installed. To install:
brew install ios-deploy
✗ CocoaPods not installed.
CocoaPods is used to retrieve the iOS platform side's plugin code that responds to your plugin usage on the Dart side.
Without resolving iOS dependencies with CocoaPods, plugins will not work on iOS.
For more info, see https://flutter.io/platform-plugins
To install:
brew install cocoapods
pod setup
[✓] Android Studio
• Android Studio at /Applications/Android Studio 3.0 Preview.app/Contents
• Java version OpenJDK Runtime Environment (build 1.8.0_152-release-915-b01)
[✓] Android Studio (version 2.3)
• Android Studio at /Applications/Android Studio.app/Contents
• Java version OpenJDK Runtime Environment (build 1.8.0_112-release-b06)
[!] IntelliJ IDEA Community Edition (version 2017.2.3)
✗ Flutter plugin not installed; this adds Flutter specific functionality.
✗ Dart plugin not installed; this adds Dart specific functionality.
• For information about installing plugins, see
https://flutter.io/intellij-setup/#installing-the-plugins
[✓] VS Code (version 1.20.1)
• VS Code at /Applications/Visual Studio Code.app/Contents
• Dart Code extension version 2.8.2
[✓] Connected devices
• Android SDK built for x86 • emulator-5554 • android-x86 • Android 7.1.1 (API 25) (emulator)
! Doctor found issues in 2 categories.
我没有使用IOS(现在)而且我正在使用VSCode ..因此问题不会导致错误......
我做了什么导致这个或者它是包中的错误吗?
答案 0 :(得分:0)
切换到master
频道或
添加
dependency_overrides:
async: ^2.0.4
到pubspec.yaml
并运行`flutter package upgrade应该解决方法,直到问题解决。