calvinckho / capacitor-jitsi-meet

This plugin is used to make video calls using Jitsi video platform (https://meet.jit.si) on iOS and Android using Ionic Capacitor.
85 stars 41 forks source link

targetSdk 34 is failing #113

Closed kumarmanishc closed 3 months ago

kumarmanishc commented 4 months ago

Hello Team,

Thank you for this Awesome plugin.

This is working fine for target sdk 33 but when we update target sdk 34 for Android 14 It's giving error

2024-07-17 19:16:17.176  6992-6992  JitsiMeetSDK            org.example.app                    E  JitsiMeetUncaughtExceptionHandler FATAL ERROR
                                                                                                    java.lang.RuntimeException: Unable to start activity ComponentInfo{org.example.app/org.example.app.MainActivity}: java.lang.SecurityException: org.example.app: One of RECEIVER_EXPORTED or RECEIVER_NOT_EXPORTED should be specified when a receiver isn't being registered exclusively for system broadcasts
                                                                                                        at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:4031)
                                                                                                        at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:4181)
                                                                                                        at android.app.servertransaction.LaunchActivityItem.execute(LaunchActivityItem.java:114)
                                                                                                        at android.app.servertransaction.TransactionExecutor.executeCallbacks(TransactionExecutor.java:144)
                                                                                                        at android.app.servertransaction.TransactionExecutor.execute(TransactionExecutor.java:101)
                                                                                                        at android.app.ActivityThread$H.handleMessage(ActivityThread.java:2643)
                                                                                                        at android.os.Handler.dispatchMessag
[7:22](https://kcssinfotech.slack.com/archives/D05TR02QMCN/p1721224348150039)

We tried following as suggestions:

The error message suggests that your broadcast receiver declaration in the AndroidManifest.xml file needs to explicitly state whether the receiver is exported or not, a requirement starting from Android 12 (API level 31). To resolve this, you need to update your AndroidManifest.xml by adding either android:exported="true" or android:exported="false" to your broadcast receiver definition. Here’s an example of how you can do this:

Example 1: Exported Receiver

If your broadcast receiver is intended to be accessible by other applications, you should set android:exported to true.

<receiver
    android:name=".YourBroadcastReceiver"
    android:exported="true">
    <intent-filter>
        <action android:name="your.intent.action" />
    </intent-filter>
</receiver>

But no luck

kcss-ashvini commented 4 months ago

I'm also experiencing the same issue @calvinckho Any of guidance or update would be highly appreciated as according to change in google play policy we have to updated targetsdk as 34 before 31st August

calvinckho commented 4 months ago

Thanks for reporting this issue. I will try to take a look this week.

calvinckho commented 4 months ago

@kumarmanishc and @kcss-ashvini, are you two still using Capacitor 5? If yes, can you try to install the latest branch #capacitor-5 using the following command and report if the error message goes away?

npm i git+ssh://git@github.com:calvinckho/capacitor-jitsi-meet#capacitor-5

calvinckho commented 4 months ago

@kumarmanishc @kcss-ashvini, any update?

kumarmanishc commented 3 months ago

@calvinckho Yes I will update you by today evening. Also is this change only available via GitHub or May I also install via npm registry?

kumarmanishc commented 3 months ago

@calvinckho Yes it seems to be working. Thank you

kcss-ashvini commented 3 months ago

@calvinckho Thank you. It's working for me as well.

calvinckho commented 3 months ago

Sounds great. capacitor-jitsi-meet@5.1.0 is released and I will close this issue.