EAS Update (Expo-Updates)

Hi there,

I’ve recently completed the builds for my app, it is working for Android & iOS but for iPad OS whenever, the app is completely closed from background and reopened fresh (hard reload) - it crashes.

This is only on the iPad version, and I have filtered down that it is the expo-updates functionality. I turned off this segment of the code and the app reopens okay on a fresh new build without the expo update code turned on.

Is there any issue with iPad OS and expo-updates right now? Is my function written out wrong?

I’ve spent days on this and no progress. Here is my version numbers & config.

  • Managed Workflow
  • “eas-cli”: “0.48.2”
  • “expo”: “^44.0.6”,
  • “expo-updates”: “^0.11.6”,
import { Alert } from "react-native";
import * as Updates from "expo-updates";


export default async function expoUpdates() {
  try {
      const update = await Updates.checkForUpdateAsync();
      if (update.isAvailable) {
          await Updates.fetchUpdateAsync();
          Alert.alert("Update Available", "App update is necessary.", [
              {
                  text: "Update",
                  onPress: async() => await Updates.reloadAsync(),
              },
          ]);
      } else if (!update.isAvailable){
           // Skip because it is current version
      }
  } catch (e) {
      Alert.alert( "Cannot update app version on Simulators",
      "\n Please use the built standalone app: " + e);
  }
}

Update

Found the bug

Essentially iOS and Android work perfectly with hermes, when hermes is enabled with expo-update on iPad OS it will crash.

Disable hermes for iOS only, make sure you run expo doctor to ensure packages are all correct and then build.

It will work.

TL;DR
Expo-updates works perfectly with hermes on iPhone etc but not on iPad. Disable hermes and make sure packages are correct with expo doctor and build. It will work 100%

1 Like

How do you disable Hermes for iOS? Cheers

Hi @maxaquilino

app.json:

{
  "expo": {
    "jsEngine": "hermes",  // default
    "ios": {
      "jsEngine": "jsc"    // override for iOS
    }
  }
}

Thanks @wodin