-
Notifications
You must be signed in to change notification settings - Fork 6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Delete v1 android engine embedding #52022
Conversation
cc @stuartmorgan, as we talked about this on flutter/packages#6494 |
Hmm actually I need to retain the contents of the interface as well, part of which references the deprecated converting to draft to figure this out |
I think this unfortunately is actually going to have to wait until we warn plugin authors, which will happen in the next stable release. io.flutter.plugin.common.PluginRegistry.Registrar references the deprecated FlutterView, which in turn references much of the rest of the v1 embedding. And there are plugins depending on being able to get a I've requested to include a section in the next "whats new in" announcement, warning plugin authors to remove this method. As soon as the next stable is released, and that announcement is made, I'll continue forward with this deletion. |
Questions I have:
|
My understanding is that the code the plugins are using isn't even part of an interface, so we don't have an effective method of deprecating it. We simply told them to include a method (which references a deprecated type from the v1 embedding), and then v1 apps would call that method expecting it existed? I'm not 100% sure on that though (how it gets called - I am 100% sure it isn't in the FlutterPlugin interface)
There isn't a direct alternative. One method was for supporting v1 apps, and the other was for supporting v2 apps. At the time of the v1 embedding deprecation our recommendation was to support both. We haven't given further guidance since then, to my knowledge.
16 of our own here flutter/packages#6494. Also the |
Also because https://docs.flutter.dev/release/breaking-changes/plugin-api-migration was written for an audience of plugin developers familiar with the v1 embedding, it might not be clear what I mean when I say "we told them to" reference a deprecated type - its specifically this portion
This registerWith method that they would have had existing in their plugins already, has a signature |
That's correct, because in previous discussions the agreement was that we would remove tool support for v1 apps (on stable) before we told plugin authors (including ourselves) to remove v1 support from their plugins. Because IMO it doesn't make sense for us to tell the ecosystem to not support a build configuration that we are still supporting in the tool. |
This is blocked on plugin outreach and soak time. |
There were some additional v1 Android embedding references missed by #6494. This PR aims to remove those missed references. I built the android example app of each plugin affected here on the [deletion branch](flutter/engine#52022) to be completely sure: Final testing, I tested that the `all_packages` app builds on the v1 embedding deletion branch: ``` $ ./.ci/scripts/create_all_packages_app.sh && cd all_packages ... $ flutter build apk --debug --local-engine-src-path=/Users/mackall/development/engine/src --local-engine=android_debug_arm64 --local-engine-host=host_debug Running Gradle task 'assembleDebug'... 4.8s � Built build/app/outputs/flutter-apk/app-debug.apk ``` � Linux repo checks are failing ``` The following packages had errors: packages/google_maps_flutter/google_maps_flutter: Missing CHANGELOG change packages/palette_generator: Missing CHANGELOG change packages/quick_actions/quick_actions: Missing CHANGELOG change packages/webview_flutter/webview_flutter: Missing CHANGELOG change ``` The only changes to these packages are `xml` changes to example apps which won't cause build failures even when the v1 embedding is deleted (they will just be unused). So I believe these changes should be version exempt.
Planning to land this this afternoon 🙏 |
…157478) flutter/engine@73c54fa...5d7caf7 2024-10-23 34871572+gmackall@users.noreply.github.com Delete v1 android engine embedding (flutter/engine#52022) 2024-10-23 41930132+hellohuanlin@users.noreply.github.com [ios][platform_view]force reset forwarding recognizer state when its stuck (flutter/engine#55958) 2024-10-23 jason-simmons@users.noreply.github.com Allow running the YAPF formatter using Python version 3.11 (flutter/engine#56062) 2024-10-23 jonahwilliams@google.com [Impeller] optimize clip rects by checking if integral coverage is sufficient. (flutter/engine#56041) 2024-10-23 a-siva@users.noreply.github.com Switch the web compilation step to use an AOT snapshot (flutter/engine#56040) If this roll has caused a breakage, revert this CL and stop the roller using the controls here: https://autoroll.skia.org/r/flutter-engine-flutter-autoroll Please CC codefu@google.com,zra@google.com on the revert to ensure that a human is aware of the problem. To file a bug in Flutter: https://github.com/flutter/flutter/issues/new/choose To report a problem with the AutoRoller itself, please file a bug: https://issues.skia.org/issues/new?component=1389291&template=1850622 Documentation for the AutoRoller is here: https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md
…7935) flutter/engine#52022 removed the Android v1 embedder. I'm seeing locally that older versions of `path_provider_android` fail due to missing symbols: ```txt flutter run Launching lib/main.dart on sdk gphone64 arm64 in debug mode... You are applying Flutter's main Gradle plugin imperatively using the apply script method, which is deprecated and will be removed in a future release. Migrate to applying Gradle plugins with the declarative plugins block: https://flutter.dev/to/flutter-gradle-plugin-apply Warning: This project is still reading the deprecated '.flutter-plugins. file. In an upcoming stable release support for this file will be completely removed and your build will fail. See https:/flutter.dev/to/flutter-plugins-configuration. /Users/matanl/.pub-cache/hosted/pub.dev/path_provider_android-2.2.2/android/src/main/java/io/flutter/plugins/pathprovider/PathProviderPlugin.java:39: error: cannot find symbol @nonnull io.flutter.plugin.common.PluginRegistry.Registrar registrar) { ^ symbol: class Registrar location: interface PluginRegistry 1 error FAILURE: Build failed with an exception. ``` To be a good citizen, let's make sure users of `path_provider` get a good `path_provider_android`.
…lutter#157478) flutter/engine@73c54fa...5d7caf7 2024-10-23 34871572+gmackall@users.noreply.github.com Delete v1 android engine embedding (flutter/engine#52022) 2024-10-23 41930132+hellohuanlin@users.noreply.github.com [ios][platform_view]force reset forwarding recognizer state when its stuck (flutter/engine#55958) 2024-10-23 jason-simmons@users.noreply.github.com Allow running the YAPF formatter using Python version 3.11 (flutter/engine#56062) 2024-10-23 jonahwilliams@google.com [Impeller] optimize clip rects by checking if integral coverage is sufficient. (flutter/engine#56041) 2024-10-23 a-siva@users.noreply.github.com Switch the web compilation step to use an AOT snapshot (flutter/engine#56040) If this roll has caused a breakage, revert this CL and stop the roller using the controls here: https://autoroll.skia.org/r/flutter-engine-flutter-autoroll Please CC codefu@google.com,zra@google.com on the revert to ensure that a human is aware of the problem. To file a bug in Flutter: https://github.com/flutter/flutter/issues/new/choose To report a problem with the AutoRoller itself, please file a bug: https://issues.skia.org/issues/new?component=1389291&template=1850622 Documentation for the AutoRoller is here: https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md
Fixes flutter/flutter#143531
Other failures from the initial attempt are fixed in flutter/flutter#146523
Pre-launch Checklist
///
).