-
Notifications
You must be signed in to change notification settings - Fork 1
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
Crash on Android #3
Comments
Is this code to reproduce this available on github? |
@mannprerak2 Yes. The main code is the same. But, there are some more work to do to reproduce it properly. Steps to reproduceBuild cronet for androidCompile the wrapper for android
Adjust the paths accordingly
There you will get the Flutter
Now all set. You can do Also attaching my cronet build here. Just in case if you don't want to build yourself. |
That quite a lot :p, I think you can wrap all this in a package. Take a loot at this -> https://github.com/Sunbreak/cronet_flutter. This works out of the box. Edit: Maybe you can use this as a starting point, put your wrapper code here and see if a similar error occurs? |
These https://github.com/Sunbreak/cronet.dart, https://github.com/Sunbreak/native_interop.tour might be helpful. cc @dcharkes |
It is a lot :/ but, most of the work is building the wrapper actually. As I was testing, I haven't put anything extra in gradle file (I'm yet to be familiar with this, that's why :/ ). If we use gradle build file, most of the task will be automated for us though.
Okay. I'll check this out. |
And, I found this: Sunbreak/cronet_flutter#8 |
One more question I need to ask. This package is a So, is there any way that we can add platform specific code and also maintain compatibility with Dart CLI? @mannprerak2 @dcharkes Context: For testing this package on flutter, I'm just importing this library and adding all the platform specific code on the main (example) project directly. In that process, I guess I'm missing something. That causes this error: Note: I have |
I suppose we can split the package into 2, maybe something like cronet and flutter_cronet. |
If I'm allowed to do that, then I'll be pushing the changes today (expected). Separating will solve many of the confusions I have now. :p |
https://github.com/google/webcrypto.dart is set up as both dart standalone package and flutter plugin. |
Wow! I'll surely look into that. For testing, I created a separate But, sadly, I'm not getting any data also. I'm still missing something. I'll update as I get some more info. |
Added android cronet lib path Reference: Issue #3
Package is working now in android. Repo: https://github.com/unsuitable001/flutter_cronet_sample (only arm64 build is provided. for other devices, have to build cronet from scratch)
Edit: Issues have been fixed. One interesting thing I encountered while checking |
Closing this issue as it has been fixed (but, the patch is in seperate repo as a seperate package). When I merge that repo to this, I'll refer this issue. Flutter package with Android support: https://github.com/unsuitable001/flutter_cronet_sample |
I get a crash whenever I try to start the cronet engine. I can get the version string without any issues though.
The log says:
The text was updated successfully, but these errors were encountered: