Closed apapalillo closed 5 months ago
I think the service is not automatically added, so you'll need to add it in your AndroidManifest.xml:
<manifest xmlns:android="http://schemas.android.com/apk/res/android">
<application android:name=".MainApplication" android:label="@string/app_name" android:icon="@mipmap/ic_launcher" android:roundIcon="@mipmap/ic_launcher_round" android:allowBackup="true" android:theme="@style/AppTheme">
...
<service android:name="com.asterinet.react.bgactions.RNBackgroundActionsTask" />
...
</application>
</manifest>
I think the service is not automatically added, so you'll need to add it in your AndroidManifest.xml:
<manifest xmlns:android="http://schemas.android.com/apk/res/android"> <application android:name=".MainApplication" android:label="@string/app_name" android:icon="@mipmap/ic_launcher" android:roundIcon="@mipmap/ic_launcher_round" android:allowBackup="true" android:theme="@style/AppTheme"> ... <service android:name="com.asterinet.react.bgactions.RNBackgroundActionsTask" /> ... </application> </manifest>
Hi pmdev71, thanks for your feedback. I also thought it could be a manifest issue, but I found out it was already correctly declared in there. Only the proguard rule fixed the issue for me.
i have same problem, the message is
FAILURE: Build failed with an exception.
What went wrong: A problem occurred configuring project ':react-native-background-actions'.
Could not create an instance of type com.android.build.api.variant.impl.LibraryVariantBuilderImpl. Namespace not specified. Please specify a namespace in the module's build.gradle file like so:
android { namespace 'com.example.namespace' }
If the package attribute is specified in the source AndroidManifest.xml, it can be migrated automatically to the namespace value in the build.gradle file using the AGP Upgrade Assistant; please refer to https://developer.android.com/studio/build/agp-upgrade-assistant for more information.
:tada: This issue has been resolved in version 4.0.0 :tada:
The release is available on:
Your semantic-release bot :package::rocket:
Hi everybody
I encountered an issue in the past days. After upgrading RN to 0.72 the background service wasn't starting anymore
After hours of debugging I figured out I needed to add an exclusion in the proguard file:
Best regards!