Attempting to call JS function on a bad application bundle

Hey all,

Just to be clear, does the proposed solution here: Expo Status - Newly built standalone apps experiencing errors not work for you?

Issue is not fixed. I’ve got users complaining about it!

The original error (Unexpected end of script) also happened for at least one of our customers after the last OTA update we made (SDK 32 with a binary built in the last few days).

They were an Android user and clearing the app data and cache solved the issue (from server logs the app must have re-downloaded the OTA update correctly when it was restarted).

So this appears to have been an issue where the OTA update download is interrupted leaving a corrupt file – the Expo runtime seems not to be able to detect this or recover from it gracefully.
Looking at the code (I think here? Exponent.java) if the app is killed at that line we’ll potentially end up with a partially written bundle file which the runtime cannot recover from unless the bundle is updated again.

A fix for this would probably be to re-trigger bundle download if runApplication throws the JSException. And/or write a bundle checksum first and verify that before trying to use it.

This certainly isn’t a common problem, but with thousands of users, it is turning up fairly frequently. We’re asking them to clear app data and re-login which gets them going again but obviously doesn’t look very good.

1 Like

This should be a severity 1 issue. Judging from the comments here, the issue is impacting many users and appears linked to the expo OTA update process.

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