r/FlutterDev • u/csells • Sep 08 '21
SDK Announcing the Flutter 2.5 stable release
Hello and welcome to Flutter 2.5! This is a big release, with the 2nd highest stats in the history of Flutter releases: 4600 issues closed and 3932 PRs merged from 252 contributors with 216 reviewers. If we look back over the last year, we see a huge 21,072 PRs created by 1337 contributors, of which 15,172 of them were merged. While the “what’s new in Flutter” blog posts focuses on new features, our #1 job with Flutter is always making sure you have the features you need at the highest possible quality level.
And in fact, this release continues a number of important performance and tooling improvements to track down performance problems in your own app. At the same time, there are a number of new features, including full screen support for Android, more Material You (also called v3) support, updated text editing to support switchable keyboard shortcuts, a new, more detailed look at your widgets in the Widget Inspector, new support for adding dependencies in your Visual Studio Code projects, new support for getting coverage information from your test runs in IntelliJ/Android Studio and a whole new app template to serve as a better foundation for your real-world Flutter apps. This release is jam-packed with exciting new updates, which you can read about in the blog post:
https://medium.com/flutter/whats-new-in-flutter-2-5-6f080c3f3dc
3
Sep 09 '21
Has there been any updates for web in this version?
3
u/csells Sep 09 '21
We continue to make improvements to web in the area of bug fixes. As far as new web features goes, the big news in this release is the camera plug-in support.
3
u/giohappy Sep 09 '21
Do you have any relevant update about desktop support?
2
u/csells Sep 09 '21
Things like text editing keyboard mappings come from our work in desktop but the desktop support itself is still in beta.
2
u/Extension-Kitchen-56 Sep 10 '21
Do you have any timeline for an official desktop support?
3
u/csells Sep 10 '21
We're working on it but have not announced a date for a stable release of desktop support for Flutter yet.
38
u/KaiN_SC Sep 08 '21
Great update but I cant update because of the android scrolling bug introduced in 2.2.6 and still not fixed.
There is an confirmred p4 open issue on github. Everyone with a longer list in their app cant basically upgrade without that non stop scrolling bug.
34
u/timsneath Sep 08 '21
Is that this bug? https://github.com/flutter/flutter/issues/84197
We'll take a look.
11
2
3
u/oodavid Sep 20 '21
Yeah, I've been waiting on this one too.
The bug has been addressed in 2.5.1:
https://github.com/flutter/flutter/wiki/Hotfixes-to-the-Stable-Channel#251-september-17-2021
3
10
u/sunbreakwang Sep 08 '21
the release announcement for Dart 2.14 is pointing to Announcing Dart 2.13
Here is the Announcing Dart 2.14
9
8
25
u/svprdga Sep 08 '21
Great. I hope that this release improves the iOS jank issue..
2
u/jkh911208 Sep 08 '21
it was "fixed", basically it was a work around for the issue.
now it is considered fixed
6
u/smpmlk Sep 08 '21
I mean, it's not super clear from the article - I assume you still need to run the shader caching process yourself and then include the sksl file in your build? This is still a work around to the underlying issue, though.
0
u/jkh911208 Sep 08 '21
may be i am missing something, but what i read previously. from 2.5 it magically warmup the shader so you don't need all those work around.
12
u/eseidelGoogle Sep 09 '21
We have some magical warmup in the works (actually a design which makes it so that shaders never have to be "warmed up" at runtime but rather are all compiled at the same time the rest of your app is), but that's still in development and not yet in any releases yet. The manual shader warmup present in this release is a useful tool for apps trying to optimize today, but is not where we believe the final architecture should be.
1
u/Silfalion Sep 09 '21
Really intrigued since it would need quite a lot of calculations with a chunky app. Is it possible to give more details at this point in time please?
9
u/eseidelGoogle Sep 09 '21
https://github.com/flutter/flutter/projects/188 is the project to follow for this and related efforts. We don't have code to share at this point, but hopefully will soon (experiments thus far have been off on branches made by individuals doing the exploring, but will end up in the main github as the work starts seeing wider review of course). With any experiments, we'll have to wait to see the results to judge success or not. :)
1
u/Silfalion Sep 09 '21
Understandably. Will keep a close eye on it and join in if I can, having been delaying diving into the core of flutter for sometime now, thank you for link:)
8
u/jonah_williams Sep 08 '21
shader warmup is not performed automatically, you need to capture shaders from a flutter run process and then build your application using the --sksl-bundle option
2
u/svprdga Sep 08 '21
If you are referring to the shader compilation warmup, I have tried it and it doesn't work to me. I would not considered this fixed until this is solved by flutter without extra efforts.
6
Sep 09 '21
[removed] — view removed comment
12
u/kayk1 Sep 09 '21
Seems more like a workaround than a fix. Should be built into the default build system.
2
Sep 13 '21
So I followed these steps and on cold boot of the app (phone restart, first install), the app now has a 4-5s white screen whilst the shaders are being compiled. Subsequent boots are fine.
Did you experience this?
2
u/svprdga Sep 09 '21
Yeah I already do that, following the exact instructions that you provide, but the jank it's still there...
6
u/guigzp Sep 08 '21
With all those improves I hope that the bug with image_picker is finally solved, really looking forward to
9
u/HallPersonal Sep 08 '21
depending on your needs, check out file_picker. i had issues with image_picker but got file_picker to work, if you have a question getting it to work, you can reply here
11
5
u/UnicornsOnLSD Sep 09 '21
Just tried it with my app. It may be placebo, but scrolling in a long list feels totally smooth now, where before there would be an occasional bit of jank. Maybe it has something to do with improvements to image GCs?
4
Sep 09 '21
Congrats on the release guys! I'm upgrading our app at work today to get the Geolocation fix for Flutter Web from Dart 2.14, I'm also excited about the new slot renderer for Web, I'm doing some fancy things with web platform views so I'll file bugs if I find any issues!
1
u/milogaosiudai Sep 09 '21 edited Sep 09 '21
finished upgrading. somehow broke my app. using the geolocator package, its now so slow when i call the getCurrentPosition method. i have also updated my geolocator package still the same.
1
u/csells Sep 09 '21
Can you share a link to an issue w/ a minimal repro that I can share with the team?
1
u/milogaosiudai Sep 09 '21
when i invoke the getCurrentPosition method, i used to provide the timeLimit parameter with duration 5 seconds. one workaround is that i remove time limit now its okay. tested only on iOS. will test later on android. thank you👍🏻
1
u/Intelligent-Ad5401 Sep 13 '21 edited Sep 13 '21
Thanks to the Flutter team for all the hard work. it is an amazing technology.
I had a question about the new App Template that is generated using
flutter create -t skeletonI am aware there was a lot of debate about which architecture / state management solution to use, and it was decided to not endorse any particular state management package. I am excited to use what the template creates.
However, in the template it references the flutter documentation
This project is a starting point for a Flutter application that follows thesimple app state management tutorial ( https://flutter.dev/docs/development/data-and-backend/state-mgmt/simple ).
Examining the source code it seems the generated app uses a combination of AnimatedBuilder and ChangeNotifier.
I can find no reference in the documentation explaining this combination. The doc, describes "Lifting Up State", accessing state using callbacks. It then mentions InheritedWidget, InheritedNotifier, InheritedModel as a way to handle more complexity, but goes onto say
"We won’t be covering those here, because they are a bit low-level for what we’re trying to do. Instead, we are going to use a package that works with the low-level widgets but is simple to use. It’s called provider."
I had a couple of questions, and forgive me if this is the wrong forum.
Could someone point me in the right direction for where the state management utilized in the new template, using AnimatedBuilder and ChangeNotifier is explained?
How would you adapt the generated code to listen to multiple ChangeNotifiers? I don´t see how you could do it with AnimatedBuilder
Thanks again.
1
u/csells Sep 13 '21
You can think of AnimatedBuilder as the ChangeNotifierProvider from provider w/o he need to add the provider package as a dependency.
I recommend upgrading to the provider package itself for handling more advanced scenarios like multiple notifiers.
1
3
u/Silfalion Sep 09 '21
Oh god, so glad. Gave been waiting for it for so long since sone packages updates ahead of time. Thank you so much for your hard work Flutter team ❤️
2
1
1
Sep 09 '21
I'm excited for the new Android edge-to-edge support! I'll try implementing this in my app ASAP! Thanks Flutter Team! 🐦
1
1
u/tdaawg Sep 09 '21
Really happy to see a focus on performance and tooling and not just visual bling :) We had a critical issue a few months back and the awesome Flutter team fixed it for us, they’re really on it 🙌
1
u/relay126 Sep 09 '21
Apart from the iOS jank, the next greatest thing with this version:
This fix: https://github.com/Dart-Code/Dart-Code/issues/3332
1
Sep 15 '21
Update seems fine. However having done the SkSL warmup pre-caching build, I'm really not impressed with the startup time added to the app on cold boot.
Granted the jank is greatly reduced, but on cold boot of the app (after first install or phone reboot) the time from splash to main screen is noticeably longer.
Really hope this shader Skia problem can be sorted.
0
Sep 09 '21
[deleted]
3
u/csells Sep 09 '21
You can open files with your desktop app today. What's holding you back?
0
Sep 09 '21
[deleted]
2
u/csells Sep 09 '21
Does "Open with" start a new instance of your app and pass the file via the command line args? Flutter apps support args now (this is a change from a previous stable release this year).
0
Sep 09 '21
[deleted]
1
u/csells Sep 09 '21
For debugging, you should be able to pass arguments to your Flutter app like so:
flutter run -d windows --dart-entrypoint-args my-arg1 my-arg2
At runtime, the args passed to the exe (assuming Windows) will be passed to the app.
You can handle the command line args via the List<String> passed to main.
0
Sep 09 '21
[deleted]
1
u/csells Sep 09 '21
No. Once you've built your exe (assuming Windows), you'll get able to pass args to your Flutter app normally and they'll show up in main normally.
18
Sep 09 '21
[removed] — view removed comment
23
u/tudor07 Sep 09 '21
I am subscribed to a lot of Flutter issues and in the past weeks like 20+ of the issues were closed due to "no recent activity", not because they were actually fixed.
25
u/MillionairePianist Sep 08 '21
This release is pretty boring tbh. I'm still excited about it and going to upgrade tonight.
To me, all that matters is Flutter web performance issues so it's viable to use in production as a truly cross platform app where we can write once and run on browser, Android, and iOS, and there doesn't seem to be anything addressing that with this release. Right now, there are still scrolling performance issues and slow load times. Besides that, it's absolutely amazing. This is really the only thing missing from making Flutter the greatest. Everything else added to it after that is bonus.
I'm still taking the risk and going forward with it for web in production, anyway, hoping this stuff is addressed more in a future release.