Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 9 additions & 5 deletions android/src/main/AndroidManifest.xml
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,14 @@
<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="android.permission.WAKE_LOCK"/>
<uses-permission android:name="android.permission.FOREGROUND_SERVICE" />
<uses-permission android:name="android.permission.FOREGROUND_SERVICE_DATA_SYNC" />
<uses-permission android:name="android.permission.FOREGROUND_SERVICE_CONNECTED_DEVICE" />
<service android:name="com.wearconnectivity.WearConnectivityTask"
android:permission="android.permission.BIND_JOB_SERVICE"
android:exported="true" />
<intent-filter>
<action android:name="com.facebook.react.HeadlessJsTaskService" />
</intent-filter>
android:permission="android.permission.FOREGROUND_SERVICE_CONNECTED_DEVICE"
android:exported="false"
Comment on lines +6 to +10

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[P0] Declare connectedDevice FGS type without raising compile SDK

The service now declares android:foregroundServiceType="dataSync|connectedDevice" and requests android.permission.FOREGROUND_SERVICE_CONNECTED_DEVICE. However the module still compiles with SDK 31 (see WearConnectivity_compileSdkVersion=31). API 31 does not define the connectedDevice foreground-service enum or the new permission, so ./gradlew :android:assemble will fail with an unknown flag during manifest processing. Either remove the Android 14-only values or bump the library’s compile/target SDKs so the build system knows about these new FGS types.

Useful? React with 👍 / 👎.

android:foregroundServiceType="dataSync|connectedDevice">
<intent-filter>
<action android:name="com.facebook.react.HeadlessJsTaskService" />
</intent-filter>
</service>
</manifest>