Skip to content

Reconcile Android/iOS on usage of a builder when creating activity/vc #33098

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

Closed
xster opened this issue May 21, 2019 · 7 comments
Closed

Reconcile Android/iOS on usage of a builder when creating activity/vc #33098

xster opened this issue May 21, 2019 · 7 comments
Assignees
Labels
a: existing-apps Integration with existing apps via the add-to-app flow engine flutter/engine repository. See also e: labels.

Comments

@xster
Copy link
Member

xster commented May 21, 2019

No description provided.

@xster xster added engine flutter/engine repository. See also e: labels. a: existing-apps Integration with existing apps via the add-to-app flow labels May 21, 2019
@kf6gpe kf6gpe added this to the December 2019 (Add-to-App) milestone Aug 29, 2019
@xster
Copy link
Member Author

xster commented Aug 29, 2019

On Android, starting an activity with a new engine has a builder (NewEngineIntentBuilder)
https://github.com/flutter/engine/blob/101e03c1c8417267c20fb9f448a8efb80ec2c328/shell/platform/android/io/flutter/embedding/android/FlutterActivity.java#L223 to specify the initial route (dart entrypoint was recently removed out of security concerns wrt android intents)

On Android, starting an engine has arguments (DartEntrypoint) https://github.com/flutter/engine/blob/101e03c1c8417267c20fb9f448a8efb80ec2c328/shell/platform/android/io/flutter/embedding/engine/dart/DartExecutor.java#L256 to specify the VM entrypoint function and the path to the dart bundle.

On iOS, starting a VC has arguments to specify the bundle (https://github.com/flutter/engine/blob/101e03c1c8417267c20fb9f448a8efb80ec2c328/shell/platform/darwin/ios/framework/Headers/FlutterViewController.h#L69) for the Flutter library and nib.

On iOS, starting the engine has arguments to specify the bundle for the Flutter library https://github.com/flutter/engine/blob/101e03c1c8417267c20fb9f448a8efb80ec2c328/shell/platform/darwin/ios/framework/Headers/FlutterEngine.h#L80.

We should be consistent about options provided when starting Flutter.

Ideally, in all cases, we should be able to provide the Flutter library location, the entrypoint and the initial route (with Android activity starting via Intent being one exception)

@xster
Copy link
Member Author

xster commented Aug 29, 2019

cc @gaaclarke, we just talked about this in person.

@xster
Copy link
Member Author

xster commented Aug 29, 2019

This doesn't solve the general platform channel timing issue such as #38914 but it would solve a lot of initial route specific timing issues, especially on iOS such as #27882, #27216.

@matthew-carroll
Copy link
Contributor

@gaaclarke do you think you've made all the changes that you want to make for this issue? Or are you still investigating API refactors?

@gaaclarke
Copy link
Member

I have nothing in the works. I gave up on FlutterEngineBuilder. I'm open to any other ideas, I've been focusing my energy elsewhere.

@matthew-carroll
Copy link
Contributor

Similar to the other ticket, let's see if we can come up with a definition of done for this ticket on Thursday. If the answer is "won't do" then we can close it on Thursday. If there is something we should do, let's see if we can define it and then we can prioritize its delivery.

@github-actions
Copy link

This thread has been automatically locked since there has not been any recent activity after it was closed. If you are still experiencing a similar issue, please open a new bug, including the output of flutter doctor -v and a minimal reproduction of the issue.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Aug 26, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
a: existing-apps Integration with existing apps via the add-to-app flow engine flutter/engine repository. See also e: labels.
Projects
None yet
Development

No branches or pull requests

4 participants