Signal-Android icon indicating copy to clipboard operation
Signal-Android copied to clipboard

Signal crashes on call screen

Open cascheberg opened this issue 10 years ago • 15 comments

Signal sometimes crashes when making a call or when receiving incoming calls. Happened a few times just now, but I haven't seen this before, so I assume it is a regression in 3.10.0 or 3.11.0. Maybe #4971?

This is all I have so far:

E/AndroidRuntime: FATAL EXCEPTION: main
Process: org.thoughtcrime.securesms, PID: 21218
java.lang.NullPointerException: Attempt to invoke virtual method 'java.lang.String android.net.Uri.toString()' on a null object reference
    at com.bumptech.glide.load.data.LocalUriFetcher.getId(LocalUriFetcher.java:69)
    at com.bumptech.glide.load.model.ImageVideoModelLoader$ImageVideoFetcher.getId(ImageVideoModelLoader.java:111)
    at com.bumptech.glide.load.engine.Engine.load(Engine.java:148)
    at com.bumptech.glide.request.GenericRequest.onSizeReady(GenericRequest.java:449)
    at com.bumptech.glide.request.RequestFutureTarget.getSize(RequestFutureTarget.java:116)
    at com.bumptech.glide.request.GenericRequest.begin(GenericRequest.java:272)
    at com.bumptech.glide.manager.RequestTracker.runRequest(RequestTracker.java:37)
    at com.bumptech.glide.GenericRequestBuilder.into(GenericRequestBuilder.java:661)
    at com.bumptech.glide.GenericRequestBuilder$1.run(GenericRequestBuilder.java:722)
    at android.os.Handler.handleCallback(Handler.java:739)
    at android.os.Handler.dispatchMessage(Handler.java:95)
    at android.os.Looper.loop(Looper.java:135)
    at android.app.ActivityThread.main(ActivityThread.java:5294)
    at java.lang.reflect.Method.invoke(Native Method)
    at java.lang.reflect.Method.invoke(Method.java:372)
    at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:904)
    at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:699)

cascheberg avatar Feb 11 '16 20:02 cascheberg

maybe someone could try to update glide to 3.7.0 as @mcginty suggested in https://github.com/WhisperSystems/Signal-Android/issues/4732#issuecomment-177927381 and see if that helps?

agrajaghh avatar Feb 11 '16 21:02 agrajaghh

Best steps I could find to reproduce:

  1. go to Android app settings
  2. force stop Signal
  3. go to Android contacts
  4. select a Signal contact
  5. select "Signal Call"
  6. Signal call screen is shown, crashes

I have not set a custom picture for this contact.

@haffenloher It did not crash when I git revert #4971

cascheberg avatar Feb 11 '16 22:02 cascheberg

Can confirm this happens constantly with the same stacktrace when trying to secure call between iOS<->Android.

ouaibe avatar Feb 12 '16 00:02 ouaibe

sounds like this is assigned to @haffenloher

moxie0 avatar Feb 12 '16 00:02 moxie0

@cascheberg can you post the unabridged log?

moxie0 avatar Feb 12 '16 18:02 moxie0

same: https://gist.github.com/b2b3ab492f053bd7030c

peterpanondrugs avatar Feb 12 '16 18:02 peterpanondrugs

https://gist.github.com/36919550acb3d7f2556a The call notification is still there after the crash.

cascheberg avatar Feb 12 '16 18:02 cascheberg

@peterpanondrugs that looks different, what problem are you experiencing?

agrajaghh avatar Feb 12 '16 18:02 agrajaghh

I can't reproduce, but can you test that @cascheberg ?

moxie0 avatar Feb 12 '16 19:02 moxie0

Doesn't crash anymore, but instead (initially) shows the default photo instead of custom one. I guess that is somewhat expected?

cascheberg avatar Feb 12 '16 20:02 cascheberg

What do you mean by initially? Does the contact have a photo?

moxie0 avatar Feb 12 '16 20:02 moxie0

Sorry, I first tested the initial config without the custom photo, that is fixed. But the current release also crashes if the contact does have a custom photo. So then I added a custom photo for that contact. For outgoing calls it now shows the default picture until the call status changes to ringing. This bug (the crash / default photo instead of custom) usually does not happen if Signal already has been loaded. Is this a problem regarding lazy loading of contact details? Not sure about how all that works...

cascheberg avatar Feb 12 '16 20:02 cascheberg

The problem is that the recipient details are populated asynchronously, that's why the URI can be null. I haven't yet found a working way to delay the contact photo fetching until after the recipient details are updated.

haffenloher avatar Feb 12 '16 20:02 haffenloher

@cascheberg Thanks I get it now. Can you try the latest master?

moxie0 avatar Feb 12 '16 20:02 moxie0

Great! Contact photo is updated in less than a second.

P.S. "asynchronous" is what I meant, not "lazy" ;)

cascheberg avatar Feb 12 '16 20:02 cascheberg