5

After updating Flutter and Dart, building app fails due to following error.

Error (Xcode): ../../.pub-cache/hosted/pub.dev/flutter_screenutil-5.6.0/lib/src/screen_util.dar t:58:5: 

Error: Type 'FlutterWindow' not found.

2 apps have same error, and it worked before updating. Other collaborator also has error after updating, but different point:

Error(Xcode): .... firebase_app.dart:18:25: Error: Member not
found:'FirebaseAppPlatform.verifyExtends'

Since We have different error, code or packages might not be the problem.

I tried flutter clean, clean build folder @Xcode, pod repo update, but still error exists.

It is very thankful if you have any solutions.

3 Answers 3

4

I solved it by changing flutter channel to stable. Type 'flutter channel' to know which branch you are currently using.
Type in terminal: 'flutter channel stable', then 'flutter upgrade'

Sign up to request clarification or add additional context in comments.

1 Comment

Thank you very much for your comment. It worked! I changed flutter channel from master to stable as you said, and error was gone. I really appreciate it.
1

Try upgrading to the latest version of packages of flutter_screenutil

Worked for me.

Comments

0

FlutterWindow API is deprecated.

Now if you are using the flutter master channel. Then edit the source code by changing the type FlutterWindow to FlutterView in all the dart files which shows the error

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.