Skip to content
This repository has been archived by the owner on Jan 27, 2024. It is now read-only.

Incompatibility of plugin with Flutter 3.7.0-13.0.pre.79 leads to build failure #6

Closed
nfnfgo opened this issue Dec 28, 2022 · 4 comments

Comments

@nfnfgo
Copy link

nfnfgo commented Dec 28, 2022

I'm using Flutter master branch, and I just pulled the lastest update and try starting my app, however I got an error from this plugin file.

My Flutter and Dart version info is below:

Flutter 3.7.0-13.0.pre.79 • channel master • https://github.com/flutter/flutter.git
Framework • revision 91c3f80c8c (15 hours ago) • 2022-12-27 04:44:24 -0500
Engine • revision 790604a09f
Tools • Dart 3.0.0 (build 3.0.0-64.0.dev) • DevTools 2.20.0

And in this version of Flutter, after I tried to start my app, I got this error (I tried flutter clean and pub get however the problem still there):

Launching lib\main.dart on sdk gphone64 x86 64 in debug mode...
lib\main.dart:1
: Error: The method '_NestedScrollMetrics.copyWith' doesn't have the named parameter 'devicePixelRatio' of overridden method 'Object with ScrollMetrics.copyWith'.
../…/src/nested_scroll_view.dart:526
  _NestedScrollMetrics copyWith({
                       ^
/C:/flutter/packages/flutter/lib/src/widgets/scroll_metrics.dart:43:17: Context: This is the overridden method ('copyWith').
  ScrollMetrics copyWith({
                ^

: Error: The superclass, 'FixedScrollMetrics', has no unnamed constructor that takes no arguments.
../…/src/nested_scroll_view.dart:514
  _NestedScrollMetrics({
  ^^^^^^^^^^^^^^^^^^^^
Target kernel_snapshot failed: Exception
2

FAILURE: Build failed with an exception.

* Where:
Script 'C:\flutter\packages\flutter_tools\gradle\flutter.gradle' line: 1157

* What went wrong:
Execution failed for task ':app:compileFlutterBuildDebug'.
> Process 'command 'C:\flutter\bin\flutter.bat'' finished with non-zero exit value 1

* Try:
> Run with --stacktrace option to get the stack trace.
> Run with --info or --debug option to get more log output.
> Run with --scan to get full insights.

* Get more help at https://help.gradle.org

BUILD FAILED in 16s
Exception: Gradle task assembleDebug failed with exit code 1
Exited (sigterm)
@idootop
Copy link
Owner

idootop commented Dec 28, 2022

Just upgrade your Flutter to the new master version.

flutter upgrade

图片

Because someone broke it 5 days ago and reverted it 5 hours ago. :(

图片

You can check it here: Flutter Commit: 999356b776f70132d569a37f13f65333a1bb0779

@idootop idootop closed this as completed Dec 28, 2022
@nfnfgo
Copy link
Author

nfnfgo commented Dec 28, 2022

It works! Thanks for answering!

@nfnfgo
Copy link
Author

nfnfgo commented Jan 19, 2023

Sorry to disturb, but seems they had relanded that commit 😭

image

And after upgrade my Flutter, the completely same error info appearred again

@idootop
Copy link
Owner

idootop commented Jan 19, 2023

-_-||| So sad, I recommand you to use the latest stable or dev channel than the master channel.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants