eas build failing during "Configure expo updates" for Android

I’m doing a POC for integrating Expo and EAS Update to an existing project.

I get the error below when trying to do eas build -p android --profile preview.

Setting the update request headers in 'AndroidManifest.xml' to '{"expo-channel-name":"preview"}'
Unexpected token ' in JSON at position 1

Here is my setup:
“react-native”: “0.68.5”
“expo”: “^45.0.8”
“expo-updates”: “^0.13.4”

eas-cli/3.7.2 darwin-arm64 node-v16.4.0

I tried digging through the codebase to pinpoint the responsible script and patch it manually but I’m having trouble tracing.
I’m hoping this is a simple compatibility/dependency version issue.

It looks like you have expo.modules.updates.UPDATES_CONFIGURATION_REQUEST_HEADERS_KEY defined in your AndroidManifest with some malformed value there, that is not a valid json.

The value I have is this:
<meta-data android:name="expo.modules.updates.UPDATES_CONFIGURATION_REQUEST_HEADERS_KEY" android:value="{'expo-channel-name':'your-channel-name'}"/>

Which was taken from Expo’s Add expo-updates to an existing project guide

I fixed the “issue” by removing the said metadata:

<meta-data android:name="expo.modules.updates.UPDATES_CONFIGURATION_REQUEST_HEADERS_KEY" android:value="{'expo-channel-name':'your-channel-name'}"/>

This topic was automatically closed 20 days after the last reply. New replies are no longer allowed.