Hello, i have an error that block my floating player to be played in some android devices not all, and when i check the error in android studio the error message lookalike:
E/AndroidRuntime: FATAL EXCEPTION: main
Process: com.BYTBFloatingta, PID: 8070
android.app.RemoteServiceException: Bad notification for startForeground: java.lang.RuntimeException: invalid channel for service notification: Notification(channel=null pri=0 contentView=com.BYTBFloatingta/0x7f0b003e vibrate=null sound=null defaults=0x0 flags=0x40 color=0x00000000 vis=PUBLIC)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1737)
at android.os.Handler.dispatchMessage(Handler.java:106)
at android.os.Looper.loop(Looper.java:193)
at android.app.ActivityThread.main(ActivityThread.java:6669)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:493)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:858)
and my code of handler.jave :
//
// Source code recreated from a .class file by IntelliJ IDEA
// (powered by Fernflower decompiler)
//
package android.os;
import android.annotation.NonNull;
import android.util.Printer;
import androidx.annotation.RecentlyNonNull;
import androidx.annotation.RecentlyNullable;
public class Handler {
public Handler() {
throw new RuntimeException("Stub!");
}
public Handler(@RecentlyNullable Handler.Callback callback) {
throw new RuntimeException("Stub!");
}
public Handler(@RecentlyNonNull Looper looper) {
throw new RuntimeException("Stub!");
}
public Handler(@RecentlyNonNull Looper looper, @RecentlyNullable Handler.Callback callback) {
throw new RuntimeException("Stub!");
}
public void handleMessage(@RecentlyNonNull Message msg) {
throw new RuntimeException("Stub!");
}
public void dispatchMessage(@RecentlyNonNull Message msg) {
throw new RuntimeException("Stub!");
}
@NonNull
public static Handler createAsync(@NonNull Looper looper) {
throw new RuntimeException("Stub!");
}
@NonNull
public static Handler createAsync(@NonNull Looper looper, @NonNull Handler.Callback callback) {
throw new RuntimeException("Stub!");
}
@RecentlyNonNull
public String getMessageName(@RecentlyNonNull Message message) {
throw new RuntimeException("Stub!");
}
@RecentlyNonNull
public final Message obtainMessage() {
throw new RuntimeException("Stub!");
}
@RecentlyNonNull
public final Message obtainMessage(int what) {
throw new RuntimeException("Stub!");
}
@RecentlyNonNull
public final Message obtainMessage(int what, @RecentlyNullable Object obj) {
throw new RuntimeException("Stub!");
}
@RecentlyNonNull
public final Message obtainMessage(int what, int arg1, int arg2) {
throw new RuntimeException("Stub!");
}
@RecentlyNonNull
public final Message obtainMessage(int what, int arg1, int arg2, @RecentlyNullable Object obj) {
throw new RuntimeException("Stub!");
}
public final boolean post(@RecentlyNonNull Runnable r) {
throw new RuntimeException("Stub!");
}
public final boolean postAtTime(@RecentlyNonNull Runnable r, long uptimeMillis) {
throw new RuntimeException("Stub!");
}
public final boolean postAtTime(@RecentlyNonNull Runnable r, @RecentlyNullable Object token, long uptimeMillis) {
throw new RuntimeException("Stub!");
}
public final boolean postDelayed(@RecentlyNonNull Runnable r, long delayMillis) {
throw new RuntimeException("Stub!");
}
public final boolean postDelayed(@RecentlyNonNull Runnable r, @RecentlyNullable Object token, long delayMillis) {
throw new RuntimeException("Stub!");
}
public final boolean postAtFrontOfQueue(@RecentlyNonNull Runnable r) {
throw new RuntimeException("Stub!");
}
public final void removeCallbacks(@RecentlyNonNull Runnable r) {
throw new RuntimeException("Stub!");
}
public final void removeCallbacks(@RecentlyNonNull Runnable r, @RecentlyNullable Object token) {
throw new RuntimeException("Stub!");
}
public final boolean sendMessage(@RecentlyNonNull Message msg) {
throw new RuntimeException("Stub!");
}
public final boolean sendEmptyMessage(int what) {
throw new RuntimeException("Stub!");
}
public final boolean sendEmptyMessageDelayed(int what, long delayMillis) {
throw new RuntimeException("Stub!");
}
public final boolean sendEmptyMessageAtTime(int what, long uptimeMillis) {
throw new RuntimeException("Stub!");
}
public final boolean sendMessageDelayed(@RecentlyNonNull Message msg, long delayMillis) {
throw new RuntimeException("Stub!");
}
public boolean sendMessageAtTime(@RecentlyNonNull Message msg, long uptimeMillis) {
throw new RuntimeException("Stub!");
}
public final boolean sendMessageAtFrontOfQueue(@RecentlyNonNull Message msg) {
throw new RuntimeException("Stub!");
}
public final void removeMessages(int what) {
throw new RuntimeException("Stub!");
}
public final void removeMessages(int what, @RecentlyNullable Object object) {
throw new RuntimeException("Stub!");
}
public final void removeCallbacksAndMessages(@RecentlyNullable Object token) {
throw new RuntimeException("Stub!");
}
public final boolean hasMessages(int what) {
throw new RuntimeException("Stub!");
}
public final boolean hasMessages(int what, @RecentlyNullable Object object) {
throw new RuntimeException("Stub!");
}
public final boolean hasCallbacks(@NonNull Runnable r) {
throw new RuntimeException("Stub!");
}
@RecentlyNonNull
public final Looper getLooper() {
throw new RuntimeException("Stub!");
}
public final void dump(@RecentlyNonNull Printer pw, @RecentlyNonNull String prefix) {
throw new RuntimeException("Stub!");
}
public String toString() {
throw new RuntimeException("Stub!");
}
public interface Callback {
boolean handleMessage(@RecentlyNonNull Message var1);
}
}
my code of looper.jave :
//
// Source code recreated from a .class file by IntelliJ IDEA
// (powered by Fernflower decompiler)
//
package android.os;
import android.annotation.NonNull;
import android.annotation.Nullable;
import android.util.Printer;
public final class Looper {
Looper(boolean quitAllowed) {
throw new RuntimeException("Stub!");
}
public static void prepare() {
throw new RuntimeException("Stub!");
}
public static void prepareMainLooper() {
throw new RuntimeException("Stub!");
}
public static Looper getMainLooper() {
throw new RuntimeException("Stub!");
}
public static void loop() {
throw new RuntimeException("Stub!");
}
@Nullable
public static Looper myLooper() {
throw new RuntimeException("Stub!");
}
@NonNull
public static MessageQueue myQueue() {
throw new RuntimeException("Stub!");
}
public boolean isCurrentThread() {
throw new RuntimeException("Stub!");
}
public void setMessageLogging(@Nullable Printer printer) {
throw new RuntimeException("Stub!");
}
public void quit() {
throw new RuntimeException("Stub!");
}
public void quitSafely() {
throw new RuntimeException("Stub!");
}
@NonNull
public Thread getThread() {
throw new RuntimeException("Stub!");
}
@NonNull
public MessageQueue getQueue() {
throw new RuntimeException("Stub!");
}
public void dump(@NonNull Printer pw, @NonNull String prefix) {
throw new RuntimeException("Stub!");
}
public String toString() {
throw new RuntimeException("Stub!");
}
}
to test my app : click here to open un playsore
you can run the app and define the error, the application work on some devices and some other don't work
Thank you in advance.
User contributions licensed under CC BY-SA 3.0