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

ReLinker still fixes issues on API 23 (Documentation bug?) #74

Open
chenposun opened this issue Mar 10, 2020 · 8 comments
Open

ReLinker still fixes issues on API 23 (Documentation bug?) #74

chenposun opened this issue Mar 10, 2020 · 8 comments

Comments

@chenposun
Copy link

Just noticed in the latest documentation you mention

If your app includes native libraries, and your minimum SDK is below API 23 (Marshmallow), you need ReLinker.

We are finding that we get java.lang.UnsatisfiedLinkError even on Marshmallow, and ReLinker fixes the issue.

Should the documentation perhaps be your minimum SDK is API 23 *and* below?

@benjamin-bader
Copy link
Contributor

Thanks, that's really interesting! My contacts on the Android team believe that all of the known library-loading bugs were fixed with the release of Marshmallow, so this would seem to be a new bug - or rather, new to them.

Happy to take a PR to update the docs!

@emartynov
Copy link

Hi people, we see native library errors even on android P:

Caused by java.lang.UnsatisfiedLinkError
dalvik.system.PathClassLoader[DexPathList[[zip file "/system/framework/org.apache.http.legacy.boot.jar", zip file "/data/app/app.my-hlN2YEi3GGzz9UjgdZx4dA==/base.apk"],nativeLibraryDirectories=[/data/app.my-hlN2YEi3GGzz9UjgdZx4dA==/lib/x86, /system/lib]]] couldn't find "libobjectbox-jni.so"

Our min sdk is 23.

Do you think that usage of relinker will help?

@benjamin-bader
Copy link
Contributor

Maybe? Give it a try and let us know.

I'm sorry to hear that this continues to be an issue, even on P.

@DanAlbert
Copy link

We (Android) don't know of any issues that would require ReLinker on OS versions that new. An app- or device-specific bug seems likely, but if you file a bug with a repro case we can help figure that out.

@emartynov
Copy link

@benjamin-bader sorry for pocking you again. We have a library dependency that tries to load native library. If we load upfront with ReLinker this library, will it be picked up later by library dependency load request?

@emartynov
Copy link

@DanAlbert I will file the ticket tomorrow, sorry for the delay.

@brianguertin
Copy link

brianguertin commented Jul 16, 2020

I'm also seeing UnsatisfiedLinkError issues for Android P users in the wild. But <1% of users are affected, and unfortunately I haven't been able to reproduce locally.

Obviously it's a platform issue but without a way to reproduce I guess we're stuck. Is there a chance ReLinker will help with unknown bugs simply because it does things a little differently? I'll give it a try, I guess.

@philippb
Copy link
Contributor

philippb commented Jul 6, 2021

@brianguertin I have only seen the bug once in my entire Android dev career at Keepsafe and was never to reproduce it.
The best thing you can do it try using ReLinker and just look at your error logs or analytics. Would be great if you could just keep this thread updated with what you see.

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

No branches or pull requests

6 participants