奇怪的Scrollview警告...在Flutter中构建APK时出现问题

时间:2018-11-04 03:20:31

标签: flutter scrollview shrinkwrap

我不知道为什么我在flutter软件包路径中看到该错误并出现收缩包装问题...并且每次我尝试生成或构建我的代码apk时,此错误都会停止编译器并显示以下消息。 / p>

PS D:\Flutter_apps\splash_screen> flutter clean
Deleting 'build\'.
PS D:\Flutter_apps\splash_screen> flutter run
Using hardware rendering with device Android SDK built for x86. If you get graphics artifacts, consider enabling software rendering with
"--enable-software-rendering".
Launching lib/main.dart on Android SDK built for x86 in debug mode...
Initializing gradle...                                           1.5s
Resolving dependencies...                                        3.0s
Gradle task 'assembleDebug'...
registerResGeneratingTask is deprecated, use registerGeneratedResFolders(FileCollection)
registerResGeneratingTask is deprecated, use registerGeneratedResFolders(FileCollection)
registerResGeneratingTask is deprecated, use registerGeneratedResFolders(FileCollection)
registerResGeneratingTask is deprecated, use registerGeneratedResFolders(FileCollection)
registerResGeneratingTask is deprecated, use registerGeneratedResFolders(FileCollection)

Compiler message:
file:///D:/flutter/packages/flutter/lib/src/widgets/scroll_view.dart:670:10: Error: Duplicated parameter name 'shrinkWrap'.
    bool shrinkWrap = false,
         ^^^^^^^^^^
file:///D:/flutter/packages/flutter/lib/src/widgets/scroll_view.dart:663:17: Error: Other parameter named 'shrinkWrap'.
  ListView(bool shrinkWrap, {
                ^^^^^^^^^^
file:///D:/flutter/packages/flutter/lib/src/material/about.dart:476:28: Error: Too few positional arguments: 1 required, 0 given.
            child: ListView(
                           ^
file:///D:/flutter/packages/flutter/lib/src/widgets/scroll_view.dart:663:3: Error: Found this candidate, but the arguments don't match.
  ListView(bool shrinkWrap, {
  ^
file:///D:/flutter/packages/flutter/lib/src/material/dropdown.dart:191:34: Error: Too few positional arguments: 1 required, 0 given.
                  child: ListView(
                                 ^
file:///D:/flutter/packages/flutter/lib/src/widgets/scroll_view.dart:663:3: Error: Found this candidate, but the arguments don't match.
  ListView(bool shrinkWrap, {
  ^
file:///D:/flutter/packages/flutter/lib/src/material/stepper.dart:544:20: Error: Too few positional arguments: 1 required, 0 given.
    return ListView(
                   ^
file:///D:/flutter/packages/flutter/lib/src/widgets/scroll_view.dart:663:3: Error: Found this candidate, but the arguments don't match.
  ListView(bool shrinkWrap, {
  ^
file:///D:/flutter/packages/flutter/lib/src/material/stepper.dart:602:26: Error: Too few positional arguments: 1 required, 0 given.
          child: ListView(
                         ^
file:///D:/flutter/packages/flutter/lib/src/widgets/scroll_view.dart:663:3: Error: Found this candidate, but the arguments don't match.
  ListView(bool shrinkWrap, {
  ^
file:///D:/flutter/packages/flutter/lib/src/material/two_level_list.dart:282:20: Error: Too few positional arguments: 1 required, 0 given.
    return ListView(
                   ^
file:///D:/flutter/packages/flutter/lib/src/widgets/scroll_view.dart:663:3: Error: Found this candidate, but the arguments don't match.
  ListView(bool shrinkWrap, {
  ^
Compiler failed on D:\Flutter_apps\splash_screen\lib/main.dart
14.7s
Gradle task assembleDebug failed with exit code 1

我什至尝试了flutter clean,但是它不起作用。...并尝试在Google上搜索它,但是找不到任何东西。

1 个答案:

答案 0 :(得分:0)

重新安装Flutter SDK可解决此问题。