Skip to content
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

Remove references to deprecated v1 Android embedding #74

Open
reidbaker opened this issue Aug 8, 2024 · 8 comments · May be fixed by #76
Open

Remove references to deprecated v1 Android embedding #74

reidbaker opened this issue Aug 8, 2024 · 8 comments · May be fixed by #76

Comments

@reidbaker
Copy link

Remove references to deprecated v1 Android embedding

To ensure this plugin will work with users running the next stable version of Flutter remove references to the v1 embedding.

The v1 embedding was deprecated around 6 and a half years ago. In Flutter 3.22, the Flutter tool dropped support for building v1 apps entirely. Flutter plans to delete version one of it's Android embedding in the next stable release, per https://medium.com/flutter/whats-new-in-flutter-3-22-fbde6c164fe3 (in the "Removal of v1 Android embedding" section).

When that deletion happens, any apps using plugins that still have references to the removed classes will fail to build when updating to the next stable version (probably Flutter 3.26).

As a part of this deprecation, the Flutter Android team is doing community outreach by filing bugs and submitting some pull requests to update plugins to minimize the impact this removal has on the community.

Some example PRs:

Consequences:

  • This change should have no impact on users of this plugin that are building apps using the v2 embedding (we don't have a percentage to share, but this is the vast majority of users).
  • It will remove support for users that are still using the v1 embedding on versions of Flutter older than 3.22.

If this change doesn't land, this plugin will instead be broken for all apps building on the next stable version of Flutter and beyond.

Is there a way to support both v1 and v2 embedding apps in the next stable version of Flutter?

No.

This is the PR where we are removing the deprecated engine classes: flutter/engine#52022

@reidbaker
Copy link
Author

flutter/engine#52022 has been merged. Users targeting Flutter master and beta/stable releases after (but not including) 3.27 will fail to compile if the plugin has references any v1 embedding classes.

To aid in identifying these classes here is a search query you can run in github on your repo.

("io.flutter.view.FlutterMain" OR "io.flutter.view.FlutterNativeView" OR "io.flutter.view.FlutterView" OR "io.flutter.embedding.engine.plugins.shim" OR "io.flutter.app" OR "PluginRegistry.Registrar")

@Milimeter
Copy link

Still no response. @reidbaker do you have a fork?

@reidbaker
Copy link
Author

I do not have a fork and will not be creating one.

@rekire
Copy link
Contributor

rekire commented Nov 10, 2024

I think the main problem with this plugin is that no updates are pushed out. E.g. a fix from me #66 was merged in march and is still not published.

@Milimeter
Copy link

I guess we just have to use your git reference then. @rekire

@Milimeter
Copy link

Milimeter commented Nov 13, 2024

@rekire the fork that you made. Was it the v1 to v2 embedding migration?

@rekire
Copy link
Contributor

rekire commented Nov 13, 2024

I am not sure, I would need to review what is actually required and what I did in the past. My guess is no.
My comment was more about that this package seems to be unmaintained at the moment.

Update:
I looked for the keyword from the second comment. There is just one hit (in my fork). Which looks IMHO like a legacy support, which can be removed, but should not break anything. However please review the requirements yourself. I won't touch my fork until I get compile errors in the future. I am not maintaining this package.

@khoadng khoadng linked a pull request Dec 16, 2024 that will close this issue
@rekire
Copy link
Contributor

rekire commented Jan 12, 2025

To use my patch from the official (this) repository you need to change the dependency to this:

  webview_cookie_manager:
    git:
      url: https://github.com/fryette/webview_cookie_manager.git
      ref: 4bb434b4a47fe806e95ffc1be28fe4366e5bbd64

The reference is the merge commit of my fix. See #66 to verify it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants