react-native-webrtc / react-native-webrtc/react-native-callkeep

Caused by java.lang.NoSuchMethodError: No virtual method stopForeground on Android 6

Open
#744 3 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Java
Stars
1.1k
Forks
511
Avg merge
9h 12m
Merged PRs (30d)
2

Description

Bug report

  • I've checked the example to reproduce the issue.

  • Reproduced on:

  • Android

  • iOS

Description

According to Crashlytics, This crash is occurring on Android 6.

stopForeground requires Android7 or higher.

Steps to Reproduce

  1. receive a call in background on Android 6.
  2. end the call via reportEndCallWithUUID

Versions

- Callkeep: 4.3.9
- React Native: 0.69.12
- iOS:
- Android: 6
- Phone model: 

Logs

Caused by java.lang.NoSuchMethodError: No virtual method stopForeground(I)V in class Lio/wazo/callkeep/VoiceConnectionService; or its super classes (declaration of 'io.wazo.callkeep.VoiceConnectionService' appears in xxx.apk)
       at io.wazo.callkeep.VoiceConnectionService.stopForegroundService(VoiceConnectionService.java:356)
       at io.wazo.callkeep.VoiceConnectionService.deinitConnection(VoiceConnectionService.java:159)
       at io.wazo.callkeep.VoiceConnection.reportDisconnect(VoiceConnection.java:167)
       at io.wazo.callkeep.RNCallKeepModule.reportEndCallWithUUID(RNCallKeepModule.java:582)
       at java.lang.reflect.Method.invoke(Method.java)
       at com.facebook.react.bridge.JavaMethodWrapper.invoke(JavaMethodWrapper.java:372)
       at com.facebook.react.bridge.JavaModuleWrapper.invoke(JavaModuleWrapper.java:188)
       at com.facebook.react.bridge.queue.NativeRunnable.run(NativeRunnable.java)
       at android.os.Handler.handleCallback(Handler.java:815)
       at android.os.Handler.dispatchMessage(Handler.java:104)
       at com.facebook.react.bridge.queue.MessageQueueThreadHandler.dispatchMessage(MessageQueueThreadHandler.java:27)
       at android.os.Looper.loop(Looper.java:207)
       at com.facebook.react.bridge.queue.MessageQueueThreadImpl$4.run(MessageQueueThreadImpl.java:228)
       at java.lang.Thread.run(Thread.java:818)

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Inspect VoiceConnectionService.java at stopForegroundService (line 356) and follow deinitConnection and reportEndCallWithUUID in the stack trace, starting with Android 6 compatibility. Reproduce ending a background call on Android 6 and verify that the flow no longer crashes.

Written by the indexing model from the issue text.

Assessment

Tech stack
android, java, react-native
Domain
mobile
Issue type
Bug
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.