Open purevnorov opened 3 years ago
I see this warning too. Any suggestions?
Yes i am seeing this as well, maybe on the next update this can be upgraded to v2 embedding?
Thank you for letting us know. I'm not sure when we'll have time to do the migration (and the testing required to make sure everything is still running correctly). Community contributions would be welcome.
any update plan?
@aminjoharinia as @vincevargadev pointed out there is no plan yet to upgrade and test it. Having said that, contributions in the form of a PR are welcome.
Hello Vince, I updated the plugin to the Android V2 embedding. So far I'm able to compile it, compile the example without the V2 warning and run on the Android emulator without errors/crashes - of course the emulator notifies 'no device' cause the WiFi is emulated. Tomorrow I will receive an ESP32 board and in the week-end I hope to check the app+plugin against a real board.
Regards
I published a pre-release version on pub.dev https://pub.dev/packages/esptouch_flutter/versions/1.1.0-androidv2
Please give it a try, and let us know if anything is not working as it did before.
If we don't receive any negative feedback, I'll release it as stable in a couple of weeks.
Good news, thanks !! I updated the plugin with the 1.1.0-androidv2 version: so far I tested on Android 7.0 API 24 and it worked. I see some new debug messages on console and in the compilation time I see the following message:
Note: C:\Progetti\flutter\.pub-cache\hosted\pub.dartlang.org\esptouch_flutter-1.1.0-androidv2\android\src\main\java\com\smaho\eng\esptouch\EsptouchPlugin.java uses or overrides a deprecated API.
Soon I will test on iOS. Thanks a lot!
It works like a charm!
I tested on iOS (16.0.2) and Android (9), the warning message disappeared. Also, I got a debug message like @SteMMo33.
Thanks for the update!
The plugin
esptouch_flutter
uses a deprecated version of the Android embedding. To avoid unexpected runtime failures, or future build failures, try to see if this plugin supports the Android V2 embedding. Otherwise, consider removing it since a future release of Flutter will remove these deprecated APIs. If you are plugin author, take a look at the docs for migrating the plugin to the V2 embedding: https://flutter.dev/go/android-plugin-migration.