Trouble with expo build:Android (Cannot read property 'status' of undefined)

Hi there,
I’m trying to build an app for android. The app has recently been upgraded from Expo SDK 27 to SDK 33. I’ve been looking at the updated instructions in the docs, but installing and reinstalling Ubuntu or the Expo CLI have not helped. I get the following error on running ‘expo build:Android’:

Metro Bundler has encountered an internal error, please check your terminal error output for more details
Unexpected end of JSON input
Failed building JavaScript bundle.
::ffff:127.0.0.1 - - [08/Jul/2019:11:02:05 +0000] “GET /node_modules/expo/AppEntry.bundle?dev=false&minify=true&hot=false&platform=ios HTTP/1.1” 500 - “-” “axios/0.19.0-beta.1”
Cannot read property ‘status’ of undefined
TypeError: Cannot read property ‘status’ of undefined
at _getForPlatformAsync (C:@expo\xdl@55.0.14\src\Project.js:163:70)
at process.internalTickCallback (internal/process/next_tick.js:77:7)

My App.json looks like this:

{
“expo”: {
“name”: “SafePlan”,
“icon”: “./Media/Images/SafePlanIcon.png”,
“version”: “1.2”,
“slug”: “safeplan”,
“sdkVersion”: “33.0.0”,
“packagerOpts”: {
“assetExts”: [“db”]
},
“orientation”: “portrait”,
“splash”: {
“image”: “./Media/Images/SafePlanSplash.png”,
“resizeMode”: “cover”
},
“ios”: {
“bundleIdentifier”: “com.nuig.safeplan”,
“usesIcloudStorage”: true
},
“android”: {
“package”: “com.nuig.safeplan”
}
}
}

And my package.json:

{
“name”: “CaatchProject”,
“version”: “0.1.0”,
“private”: true,
“devDependencies”: {
“babel-plugin-transform-remove-console”: “^6.9.4”,
“jest-expo”: “^33.0.0”,
“react-test-renderer”: “16.3.1”
},
“main”: “node_modules/expo/AppEntry.js”,
“scripts”: {
“start”: “expo start”,
“eject”: “expo eject”,
“android”: “expo start --android”,
“ios”: “expo start --ios”,
“test”: “jest”
},
“jest”: {
“preset”: “jest-expo”
},
“dependencies”: {
“expo”: “^33.0.0”,
“expo-constants”: “^5.0.1”,
“expo-file-system”: “^5.0.1”,
“expo-font”: “^5.0.1”,
“expo-image-picker”: “^5.0.2”,
“expo-permissions”: “^5.0.1”,
“expo-sqlite”: “^5.0.1”,
“moment”: “^2.22.2”,
“native-base”: “^2.6.1”,
“prop-types”: “^15.6.1”,
“react”: “16.8.3”,
“react-native”: “https://github.com/expo/react-native/archive/sdk-33.0.0.tar.gz”,
“react-native-accordion”: “^1.0.1”,
“react-native-calendars”: “^1.19.3”,
“react-native-chart-kit”: “^1.1.5”,
“react-native-collapsible”: “^0.12.0”,
“react-native-communications”: “^2.2.1”,
“react-native-dialog”: “^5.4.0”,
“react-native-elements”: “^0.19.1”,
“react-native-elevated-view”: “0.0.6”,
“react-native-image-view”: “^2.1.1”,
“react-native-image-zoom-viewer”: “^2.2.13”,
“react-native-input-scroll-view”: “^1.7.1”,
“react-native-keyboard-aware-scroll-view”: “^0.6.0”,
“react-native-keyboard-spacer”: “^0.4.1”,
“react-native-modal-datetime-picker”: “^6.0.0”,
“react-native-modal-selector”: “0.0.28”,
“react-native-multiple-select-list”: “^1.0.4”,
“react-native-open-maps”: “^0.3.1”,
“react-native-picker-select”: “^4.4.0”,
“react-native-pin-code”: “^0.4.1”,
“react-native-scalable-image”: “^0.4.0”,
“react-native-slider”: “^0.11.0”,
“react-native-snap-carousel”: “^3.7.4”,
“react-native-snap-slider”: “^0.3.0”,
“react-native-swipeable”: “^0.6.0”,
“react-native-vector-icons”: “^4.6.0”,
“react-navigation”: “^2.18.2”,
“react-redux”: “^5.0.7”,
“react-timer-mixin”: “^0.13.4”,
“redux”: “^4.0.0”,
“tcomb-form-native”: “git+https://github.com/conbag/tcomb-form-native.git#app-version”,
“victory-native”: “^30.1.0”
}
}

Any idea where I might be going wrong?
I’ve tried reinstalling Ubuntu and the Expo CLI, my OS is Windows 10.

Hey @lark,

Did you incrementally upgrade SDK versions or did you jump from 27 → 33? If you jumped, it may be worth incrementally upgrading and pinpointing when the change occurs.

Cheers,
Adam

Hi Adam,
I had updated incrementally. I was able to upgrade in the end, by copying the project from one directory to another.

Thanks for your help regardless!

Glad you got things sorted out!

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