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
Link assemblies is crashing #3376
Comments
I am unable to repo locally on Xamarin.Android Version: 9.4.0.51 . Normally the The main difference it seems is my SDK Tooling has different versions
Can you try upgrading your tools to the latest versions and see if that helps. If that does not help , can you provide a sample app which will demonstrate the issue. |
Is not the API 29 for Android Q that is still in Beta? Also, I posted both projects here: |
Also, I attached this one that is having issues too: https://drive.google.com/open?id=1SkBx9IXv6ZSoi2PF6G4r02hjnL4MM0fq |
It works in Debug mode with the SDK 29, but not in Release. |
I think you need to add these lines into the ProGuard.cfg file:
The linker removes classes that are needed and apparently doesn't parse the axml to see that they are in fact needed |
As far as I remember ProGuard is legacy, right? I'm using R8 for the projects. Do you something about it? Also, I'm using only XMLs, should I use AXMLs? Thanks for the clarifications. |
The ProGuard file is still used, even when using R8. Just my guesses though, I am not a Xamarin team member |
RE: |
This one didn't work. |
@FANMixco can you post an updated project where you added these rules? It seems like that should fix your issue. Thanks! Just a couple notes:
|
It didn't work as I said. New project: https://drive.google.com/open?id=1_f28lo0NPT2OZNCTZROnPpCiPssSetgF |
Can you post the full diagnostic build log here? This screenshot is a linker error and completely different than a crash at runtime. I think we might be confusing two different problems here. |
Yes, I know and it started to happen in the latest edition of VS for Mac. I cannot reproduce the previous error since I cannot do it anymore. |
Could you have just modified your If so, we found/fixed an issue that might be the problem here: #3405 Is the runtime error still happening? |
I haven't changed anything. I only did this: If it was automatically changed by VS for Mac, then that's the answer, but I didn't change anything and the bug that I showed happened almost 2 weeks ago, this is the current version that I have:
In this project it happens: https://drive.google.com/open?id=1ka2iNlzrD57aD_3K8Yt7hzfyPlCQNOj0 I haven't done any change and the other one I cannot reproduce it since it's crashing since this release. |
So the
So it does seem like the proguard rules fix something, just on to the next issue. Your Is this other project you linked to the same issue? or something else? |
Yes, this is the other project and it has other issues in certain cases, but I have never seen that one. |
I don't see this So your code here is probably breaking on newer devices; I have a Pixel 3 XL running Android 9.0 Pie. |
I have all my Apps running in Android Pie too with a Xiaomi A2 Lite and I don't have any issue regarding this (no compression and linking). |
Ah you are logging this and going on: https://github.com/FANMixco/Xamarin-SearchBar/blob/c30762a1d3a8c40242a5af022b996d0989206dca/tk.supernovaic.MaterialSearchBar/MaterialSearchBar.cs#L384-L391 The actual error is:
I adjusted the rules to:
Then it worked. |
@FANMixco I think we resolved what was going on here, right? The issue was proguard/r8 removing Let me know and we can reopen if needed, thanks! |
Steps to Reproduce
android:fitsSystemWindows="true"
Example:
Expected Behavior
Run as expected.
Actual Behavior
Crashing on running.
Version Information
This issue is from the current stable to the latest preview.
Log File
The text was updated successfully, but these errors were encountered: