I have been trying to clone and run this time-messenger app from GitHub . But I keep getting this error. I tried flutter doctor
, flutter clean
, flutter build
apk (which also gave an error), flutter pub cache repair
, flutter pub get
and so on but it didn't work.
This is the error I'm getting:
punreachrany@Punreachs-MacBook-Pro timy-messenger-master % flutter run
Using hardware rendering with device sdk gphone x86 arm. If you get graphics
artifacts, consider enabling software rendering with
"--enable-software-rendering".
Launching lib/main.dart on sdk gphone x86 arm in debug mode...
Compiler message:
../../../Developer/flutter/.pub-cache/hosted/pub.dartlang.org/flutter_platform_w
idgets-0.20.2/lib/src/platform_scaffold.dart:229:38: Error: The getter
'fullObstruction' isn't defined for the class 'ObstructingPreferredSizeWidget'.
- 'ObstructingPreferredSizeWidget' is from
'package:flutter/src/cupertino/page_scaffold.dart'
('../../../Developer/flutter/packages/flutter/lib/src/cupertino/page_scaffold.d
art').
Try correcting the name to the name of an existing getter, or defining a getter
or field named 'fullObstruction'.
final obstruct = navigationBar.fullObstruction == null ||
^^^^^^^^^^^^^^^
../../../Developer/flutter/.pub-cache/hosted/pub.dartlang.org/flutter_platform_w
idgets-0.20.2/lib/src/platform_scaffold.dart:230:25: Error: The getter
'fullObstruction' isn't defined for the class 'ObstructingPreferredSizeWidget'.
- 'ObstructingPreferredSizeWidget' is from
'package:flutter/src/cupertino/page_scaffold.dart'
('../../../Developer/flutter/packages/flutter/lib/src/cupertino/page_scaffold.d
art').
Try correcting the name to the name of an existing getter, or defining a getter
or field named 'fullObstruction'.
navigationBar.fullObstruction;
^^^^^^^^^^^^^^^
Compiler message:
../../../Developer/flutter/.pub-cache/hosted/pub.dartlang.org/flutter_platform_widgets-0.20.2/lib/src/platform_scaffold.dart:229:38: Error: The getter 'fullObstruction' isn't defined for the class 'ObstructingPreferredSizeWidget'.
- 'ObstructingPreferredSizeWidget' is from 'package:flutter/src/cupertino/page_scaffold.dart' ('../../../Developer/flutter/packages/flutter/lib/src/cupertino/page_scaffold.dart').
Try correcting the name to the name of an existing getter, or defining a getter or field named 'fullObstruction'.
final obstruct = navigationBar.fullObstruction == null ||
^^^^^^^^^^^^^^^
../../../Developer/flutter/.pub-cache/hosted/pub.dartlang.org/flutter_platform_widgets-0.20.2/lib/src/platform_scaffold.dart:230:25: Error: The getter 'fullObstruction' isn't defined for the class 'ObstructingPreferredSizeWidget'.
- 'ObstructingPreferredSizeWidget' is from 'package:flutter/src/cupertino/page_scaffold.dart' ('../../../Developer/flutter/packages/flutter/lib/src/cupertino/page_scaffold.dart').
Try correcting the name to the name of an existing getter, or defining a getter or field named 'fullObstruction'.
navigationBar.fullObstruction;
^^^^^^^^^^^^^^^
Target kernel_snapshot failed: Exception: Errors during snapshot creation: null
build failed.
FAILURE: Build failed with an exception.
* Where:
Script '/Users/punreachrany/Developer/flutter/packages/flutter_tools/gradle/flutter.gradle' line: 882
* What went wrong:
Execution failed for task ':app:compileFlutterBuildDebug'.
> Process 'command '/Users/punreachrany/Developer/flutter/bin/flutter'' 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 9s
Running Gradle task 'assembleDebug'...
Running Gradle task 'assembleDebug'... Done 9,7s
Exception: Gradle task assembleDebug failed with exit code 1
punreachrany@Punreachs-MacBook-Pro timy-messenger-master %
What can I try next? Project Link: https://github.com/janoodleFTW/timy-messenger
Change the version number of flutter_platform_widgets
to ^0.32.4
in pubspec.yaml
, then run flutter packages upgrade
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.