"SyntaxError: Unexpected end of input" when building with Ionic Cloud

Hi,

I am new to Ionic Cloud and trying to build for iOS.
After the setup http://docs.ionic.io/setup.html and the instructions there http://docs.ionic.io/services/package/#building, I get the following error:

Caught exception:
SyntaxError: Unexpected end of input
at Object.parse (native)
at Request._callback (/usr/local/lib/node_modules/ionic/node_modules/ionic-app-lib/lib/package.js:117:27)
at Request.self.callback (/usr/local/lib/node_modules/ionic/node_modules/ionic-app-lib/node_modules/request/request.js:373:22)
at emitTwo (events.js:87:13)
at Request.emit (events.js:172:7)
at Request. (/usr/local/lib/node_modules/ionic/node_modules/ionic-app-lib/node_modules/request/request.js:1318:14)
at emitOne (events.js:82:20)
at Request.emit (events.js:169:7)
at IncomingMessage. (/usr/local/lib/node_modules/ionic/node_modules/ionic-app-lib/node_modules/request/request.js:1266:12)
at emitNone (events.js:72:20)

Mind letting us know? https://github.com/driftyco/ionic-cli/issues

My information:

Cordova CLI: 6.3.1
Ionic Framework Version: 2.0.0-rc.5
Ionic CLI Version: 2.2.1
Ionic App Lib Version: 2.2.0
Ionic App Scripts Version: 1.0.0
ios-deploy version: Not installed
ios-sim version: Not installed
OS: Linux 4.4
Node Version: v4.2.6
Xcode version: Not installed

My package.json:

{
“name”: “test”,
“author”: “Test”,
“homepage”: “http://a-test.com/”,
“private”: true,
“scripts”: {
“clean”: “ionic-app-scripts clean”,
“build”: “ionic-app-scripts build”,
“ionic:build”: “ionic-app-scripts build”,
“ionic:serve”: “ionic-app-scripts serve”
},
“dependencies”: {
"@angular/common": “2.2.1”,
"@angular/compiler": “2.2.1”,
"@angular/compiler-cli": “2.2.1”,
"@angular/core": “2.2.1”,
"@angular/forms": “2.2.1”,
"@angular/http": “2.2.1”,
"@angular/platform-browser": “2.2.1”,
"@angular/platform-browser-dynamic": “2.2.1”,
"@angular/platform-server": “2.2.1”,
"@ionic/cloud-angular": “^0.10.0”,
"@ionic/storage": “1.1.7”,
"@types/google-maps": “^3.2.0”,
“angular2-jwt”: “^0.1.27”,
“ionic-angular”: “2.0.0-rc.5”,
“ionic-native”: “2.2.11”,
“ionicons”: “3.0.0”,
“rxjs”: “5.0.0-beta.12”,
“sw-toolbox”: “3.4.0”,
“zone.js”: “0.6.26”
},
“devDependencies”: {
"@ionic/app-scripts": “1.0.0”,
“typescript”: “2.0.9”
},
“cordovaPlugins”: [
“cordova-plugin-whitelist”,
“cordova-plugin-statusbar”,
“cordova-plugin-device”,
“cordova-plugin-console”,
“ionic-plugin-keyboard”,
“cordova-plugin-splashscreen”,
“cordova-sqlite-storage”,
“phonegap-plugin-barcodescanner”,
“cordova-plugin-compat”,
“cordova-plugin-geolocation”,
“cordova-plugin-inappbrowser”,
{
“id”: “cordova-plugin-facebook4”,
“locator”: “cordova-plugin-facebook4”,
“variables”: {
“APP_ID”: “1234567890”,
“APP_NAME”: “test”
}
}
],
“cordovaPlatforms”: [
{
“platform”: “android”,
“version”: “”,
“locator”: “android”
}
],
“description”: “None”
}

I also tried to update Ionic to the latest version, removed the app_id (as mentionned here Ionic package error) or remove node_modules to run npm install, but to no avail.

Any help is welcome!
Big thanks :slight_smile:

same

Best regards,
Siarhei

Seems like it was a bug. The error we were getting was different, but after Ionic team reported a fix here:

I can build now. Thanks!

Hello bro! I have also the same problem please give the solution of such problem. plz help on these issue.

C:\Users\Amol-PC\WeatherIonic1>ionic serve

ionic-app-scripts.cmd serve --address localhost --port 8100 --livereload-port 35729 --dev-logger-port 53703 --nobrowser
[app-scripts] C:\Users\Amol-PC\WeatherIonic1\node_modules@ionic\app-scripts\dist\aot\aot-compiler.js:203
[app-scripts] var ngTools2, angularCompilerHost, program,
[app-scripts]
[app-scripts] SyntaxError: Unexpected end of input
[app-scripts] at wrapSafe (internal/modules/cjs/loader.js:984:16)
[app-scripts] at Module._compile (internal/modules/cjs/loader.js:1032:27)
[app-scripts] at Object.Module._extensions…js (internal/modules/cjs/loader.js:1097:10)
[app-scripts] at Module.load (internal/modules/cjs/loader.js:933:32)
[app-scripts] at Function.Module._load (internal/modules/cjs/loader.js:774:14)
[app-scripts] at Module.require (internal/modules/cjs/loader.js:957:19)
[app-scripts] at require (internal/modules/cjs/helpers.js:88:18)
[app-scripts] at Object. (C:\Users\Amol-PC\WeatherIonic1\node_modules@ionic\app-scripts\dist\ngc.js:3:22)
[app-scripts] at Module._compile (internal/modules/cjs/loader.js:1068:30)
[app-scripts] at Object.Module._extensions…js (internal/modules/cjs/loader.js:1097:10)

[ERROR] ionic-app-scripts has unexpectedly closed (exit code 1).

    The Ionic CLI will exit. Please check any output above for error details.