[TIMOB-24939] iOS 11: Build crashes with "Cannot read property 'forEach' of undefined"
GitHub Issue | n/a |
---|---|
Type | Bug |
Priority | Critical |
Status | Closed |
Resolution | Duplicate |
Resolution Date | 2017-07-06T16:14:17.000+0000 |
Affected Version/s | Release 6.2.0 |
Fix Version/s | n/a |
Components | iOS |
Labels | ios11, xcode9 |
Reporter | Hans Knöchel |
Assignee | Chris Barber |
Created | 2017-07-06T02:14:02.000+0000 |
Updated | 2018-08-06T17:41:06.000+0000 |
Description
When running a fresh app with master (6.2.0.v20170705124957), the app immediately crashes with the following error:
/Users/hknoechel/Library/Application Support/Titanium/mobilesdk/osx/6.2.0.v20170705124957/node_modules/ioslib/node_modules/async/dist/async.js:5174
callback.apply(null, [null].concat(args));
^
TypeError: Cannot read property 'forEach' of undefined
at /Users/hknoechel/Library/Application Support/Titanium/mobilesdk/osx/6.2.0.v20170705124957/node_modules/ioslib/lib/simulator.js:230:24
at Array.forEach (native)
at /Users/hknoechel/Library/Application Support/Titanium/mobilesdk/osx/6.2.0.v20170705124957/node_modules/ioslib/lib/simulator.js:198:16
at Array.forEach (native)
at /Users/hknoechel/Library/Application Support/Titanium/mobilesdk/osx/6.2.0.v20170705124957/node_modules/ioslib/lib/simulator.js:192:25
at Array.forEach (native)
at /Users/hknoechel/Library/Application Support/Titanium/mobilesdk/osx/6.2.0.v20170705124957/node_modules/ioslib/lib/simulator.js:191:31
at /Users/hknoechel/Library/Application Support/Titanium/mobilesdk/osx/6.2.0.v20170705124957/node_modules/ioslib/lib/simctl.js:223:4
at /Users/hknoechel/Library/Application Support/Titanium/mobilesdk/osx/6.2.0.v20170705124957/node_modules/ioslib/node_modules/async/dist/async.js:906:16
at next (/Users/hknoechel/Library/Application Support/Titanium/mobilesdk/osx/6.2.0.v20170705124957/node_modules/ioslib/node_modules/async/dist/async.js:5174:18)
---------------------------------------------
at Object.run (/Users/hknoechel/Library/Application Support/Titanium/mobilesdk/osx/6.2.0.v20170705124957/node_modules/node-appc/lib/subprocess.js:59:8)
at /Users/hknoechel/Library/Application Support/Titanium/mobilesdk/osx/6.2.0.v20170705124957/node_modules/ioslib/lib/simctl.js:581:20
at Object.whilst (/Users/hknoechel/Library/Application Support/Titanium/mobilesdk/osx/6.2.0.v20170705124957/node_modules/ioslib/node_modules/async/dist/async.js:5176:5)
at trySimctl (/Users/hknoechel/Library/Application Support/Titanium/mobilesdk/osx/6.2.0.v20170705124957/node_modules/ioslib/lib/simctl.js:575:8)
at /Users/hknoechel/Library/Application Support/Titanium/mobilesdk/osx/6.2.0.v20170705124957/node_modules/ioslib/lib/simctl.js:177:4
at Object.whilst (/Users/hknoechel/Library/Application Support/Titanium/mobilesdk/osx/6.2.0.v20170705124957/node_modules/ioslib/node_modules/async/dist/async.js:5176:5)
at Object.list (/Users/hknoechel/Library/Application Support/Titanium/mobilesdk/osx/6.2.0.v20170705124957/node_modules/ioslib/lib/simctl.js:172:8)
at /Users/hknoechel/Library/Application Support/Titanium/mobilesdk/osx/6.2.0.v20170705124957/node_modules/ioslib/lib/simulator.js:179:11
at fireCallbacks (/Users/hknoechel/Library/Application Support/Titanium/mobilesdk/osx/6.2.0.v20170705124957/node_modules/ioslib/lib/xcode.js:122:5)
---------------------------------------------
at Object.run (/Users/hknoechel/Library/Application Support/Titanium/mobilesdk/osx/6.2.0.v20170705124957/node_modules/node-appc/lib/subprocess.js:59:8)
at /Users/hknoechel/Library/Application Support/Titanium/mobilesdk/osx/6.2.0.v20170705124957/node_modules/ioslib/lib/xcode.js:449:23
at /Users/hknoechel/Library/Application Support/Titanium/mobilesdk/osx/6.2.0.v20170705124957/node_modules/ioslib/node_modules/async/dist/async.js:3060:16
at eachOfArrayLike (/Users/hknoechel/Library/Application Support/Titanium/mobilesdk/osx/6.2.0.v20170705124957/node_modules/ioslib/node_modules/async/dist/async.js:1003:9)
at eachOf (/Users/hknoechel/Library/Application Support/Titanium/mobilesdk/osx/6.2.0.v20170705124957/node_modules/ioslib/node_modules/async/dist/async.js:1051:5)
at Object.eachLimit (/Users/hknoechel/Library/Application Support/Titanium/mobilesdk/osx/6.2.0.v20170705124957/node_modules/ioslib/node_modules/async/dist/async.js:3122:5)
at /Users/hknoechel/Library/Application Support/Titanium/mobilesdk/osx/6.2.0.v20170705124957/node_modules/ioslib/lib/xcode.js:441:12
at /Users/hknoechel/Library/Application Support/Titanium/mobilesdk/osx/6.2.0.v20170705124957/node_modules/node-appc/lib/subprocess.js:100:8
at ChildProcess.<anonymous> (/Users/hknoechel/Library/Application Support/Titanium/mobilesdk/osx/6.2.0.v20170705124957/node_modules/node-appc/lib/subprocess.js:60:3)
---------------------------------------------
at Object.run (/Users/hknoechel/Library/Application Support/Titanium/mobilesdk/osx/6.2.0.v20170705124957/node_modules/node-appc/lib/subprocess.js:59:8)
at find (/Users/hknoechel/Library/Application Support/Titanium/mobilesdk/osx/6.2.0.v20170705124957/node_modules/node-appc/lib/subprocess.js:96:14)
at /Users/hknoechel/Library/Application Support/Titanium/mobilesdk/osx/6.2.0.v20170705124957/node_modules/async/dist/async.js:4025:5
at process (/Users/hknoechel/Library/Application Support/Titanium/mobilesdk/osx/6.2.0.v20170705124957/node_modules/async/dist/async.js:2332:17)
at Immediate.<anonymous> (/Users/hknoechel/Library/Application Support/Titanium/mobilesdk/osx/6.2.0.v20170705124957/node_modules/async/dist/async.js:2136:16)
at runCallback (timers.js:672:20)
at tryOnImmediate (timers.js:645:5)
at processImmediate [as _immediateCallback] (timers.js:617:5)
---------------------------------------------
at /Users/hknoechel/Library/Application Support/Titanium/mobilesdk/osx/6.2.0.v20170705124957/node_modules/async/dist/async.js:2135:9
at apply (/Users/hknoechel/Library/Application Support/Titanium/mobilesdk/osx/6.2.0.v20170705124957/node_modules/async/dist/async.js:21:25)
at /Users/hknoechel/Library/Application Support/Titanium/mobilesdk/osx/6.2.0.v20170705124957/node_modules/async/dist/async.js:56:12
at _insert (/Users/hknoechel/Library/Application Support/Titanium/mobilesdk/osx/6.2.0.v20170705124957/node_modules/async/dist/async.js:2248:9)
at Object.push (/Users/hknoechel/Library/Application Support/Titanium/mobilesdk/osx/6.2.0.v20170705124957/node_modules/async/dist/async.js:2294:13)
at Object.findExecutable (/Users/hknoechel/Library/Application Support/Titanium/mobilesdk/osx/6.2.0.v20170705124957/node_modules/node-appc/lib/subprocess.js:113:8)
at findTeams (/Users/hknoechel/Library/Application Support/Titanium/mobilesdk/osx/6.2.0.v20170705124957/node_modules/ioslib/lib/xcode.js:431:21)
at /Users/hknoechel/Library/Application Support/Titanium/mobilesdk/osx/6.2.0.v20170705124957/node_modules/ioslib/node_modules/async/dist/async.js:3830:24
at replenish (/Users/hknoechel/Library/Application Support/Titanium/mobilesdk/osx/6.2.0.v20170705124957/node_modules/ioslib/node_modules/async/dist/async.js:946:17)
---------------------------------------------
at Object.run (/Users/hknoechel/Library/Application Support/Titanium/mobilesdk/osx/6.2.0.v20170705124957/node_modules/node-appc/lib/subprocess.js:59:8)
at /Users/hknoechel/Library/Application Support/Titanium/mobilesdk/osx/6.2.0.v20170705124957/node_modules/ioslib/lib/xcode.js:415:22
at /Users/hknoechel/Library/Application Support/Titanium/mobilesdk/osx/6.2.0.v20170705124957/node_modules/ioslib/node_modules/async/dist/async.js:3060:16
at replenish (/Users/hknoechel/Library/Application Support/Titanium/mobilesdk/osx/6.2.0.v20170705124957/node_modules/ioslib/node_modules/async/dist/async.js:946:17)
at iterateeCallback (/Users/hknoechel/Library/Application Support/Titanium/mobilesdk/osx/6.2.0.v20170705124957/node_modules/ioslib/node_modules/async/dist/async.js:931:17)
at /Users/hknoechel/Library/Application Support/Titanium/mobilesdk/osx/6.2.0.v20170705124957/node_modules/ioslib/node_modules/async/dist/async.js:906:16
at /Users/hknoechel/Library/Application Support/Titanium/mobilesdk/osx/6.2.0.v20170705124957/node_modules/ioslib/lib/xcode.js:425:7
at ChildProcess.<anonymous> (/Users/hknoechel/Library/Application Support/Titanium/mobilesdk/osx/6.2.0.v20170705124957/node_modules/node-appc/lib/subprocess.js:60:3)
---------------------------------------------
at Object.run (/Users/hknoechel/Library/Application Support/Titanium/mobilesdk/osx/6.2.0.v20170705124957/node_modules/node-appc/lib/subprocess.js:59:8)
at /Users/hknoechel/Library/Application Support/Titanium/mobilesdk/osx/6.2.0.v20170705124957/node_modules/ioslib/lib/xcode.js:415:22
at /Users/hknoechel/Library/Application Support/Titanium/mobilesdk/osx/6.2.0.v20170705124957/node_modules/ioslib/node_modules/async/dist/async.js:3060:16
at replenish (/Users/hknoechel/Library/Application Support/Titanium/mobilesdk/osx/6.2.0.v20170705124957/node_modules/ioslib/node_modules/async/dist/async.js:946:17)
at /Users/hknoechel/Library/Application Support/Titanium/mobilesdk/osx/6.2.0.v20170705124957/node_modules/ioslib/node_modules/async/dist/async.js:950:9
at eachLimit$1 (/Users/hknoechel/Library/Application Support/Titanium/mobilesdk/osx/6.2.0.v20170705124957/node_modules/ioslib/node_modules/async/dist/async.js:3146:24)
at Object.<anonymous> (/Users/hknoechel/Library/Application Support/Titanium/mobilesdk/osx/6.2.0.v20170705124957/node_modules/ioslib/node_modules/async/dist/async.js:980:16)
at loadXcodeInfo (/Users/hknoechel/Library/Application Support/Titanium/mobilesdk/osx/6.2.0.v20170705124957/node_modules/ioslib/lib/xcode.js:276:11)
at /Users/hknoechel/Library/Application Support/Titanium/mobilesdk/osx/6.2.0.v20170705124957/node_modules/ioslib/node_modules/async/dist/async.js:3830:24
---------------------------------------------
at Object.run (/Users/hknoechel/Library/Application Support/Titanium/mobilesdk/osx/6.2.0.v20170705124957/node_modules/node-appc/lib/subprocess.js:59:8)
at /Users/hknoechel/Library/Application Support/Titanium/mobilesdk/osx/6.2.0.v20170705124957/node_modules/ioslib/lib/xcode.js:239:22
at /Users/hknoechel/Library/Application Support/Titanium/mobilesdk/osx/6.2.0.v20170705124957/node_modules/ioslib/lib/env.js:98:4
at /Users/hknoechel/Library/Application Support/Titanium/mobilesdk/osx/6.2.0.v20170705124957/node_modules/ioslib/node_modules/async/dist/async.js:3838:9
at /Users/hknoechel/Library/Application Support/Titanium/mobilesdk/osx/6.2.0.v20170705124957/node_modules/ioslib/node_modules/async/dist/async.js:421:16
at iterateeCallback (/Users/hknoechel/Library/Application Support/Titanium/mobilesdk/osx/6.2.0.v20170705124957/node_modules/ioslib/node_modules/async/dist/async.js:928:24)
at /Users/hknoechel/Library/Application Support/Titanium/mobilesdk/osx/6.2.0.v20170705124957/node_modules/ioslib/node_modules/async/dist/async.js:906:16
at /Users/hknoechel/Library/Application Support/Titanium/mobilesdk/osx/6.2.0.v20170705124957/node_modules/ioslib/node_modules/async/dist/async.js:3835:13
at /Users/hknoechel/Library/Application Support/Titanium/mobilesdk/osx/6.2.0.v20170705124957/node_modules/ioslib/lib/env.js:76:6
---------------------------------------------
at Object.run (/Users/hknoechel/Library/Application Support/Titanium/mobilesdk/osx/6.2.0.v20170705124957/node_modules/node-appc/lib/subprocess.js:59:8)
at find (/Users/hknoechel/Library/Application Support/Titanium/mobilesdk/osx/6.2.0.v20170705124957/node_modules/node-appc/lib/subprocess.js:96:14)
at /Users/hknoechel/Library/Application Support/Titanium/mobilesdk/osx/6.2.0.v20170705124957/node_modules/async/dist/async.js:4025:5
at process (/Users/hknoechel/Library/Application Support/Titanium/mobilesdk/osx/6.2.0.v20170705124957/node_modules/async/dist/async.js:2332:17)
at Immediate.<anonymous> (/Users/hknoechel/Library/Application Support/Titanium/mobilesdk/osx/6.2.0.v20170705124957/node_modules/async/dist/async.js:2136:16)
at runCallback (timers.js:672:20)
at tryOnImmediate (timers.js:645:5)
at processImmediate [as _immediateCallback] (timers.js:617:5)
I think I had a related error a few weeks before, but not sure if I filed a ticket back then. Feel free to mark as duplicate if so. Thx!
To reproduce:
1. Create a new app with appc new -p ios
2. Run the app
3. Build crashes
This error is no longer valid... or at least it's no longer valid once you finish reviewing and merging https://github.com/appcelerator/titanium_mobile/pull/9173 and resolve TIMOB-24798.
This issue is not resolved with the mentioned PR, getting the same error when building the SDK from that branch.
After looking at it again, I do not believe it's possible to receive the error you are seeing with ioslib@1.4.8. Make sure you are scons'ing the correct branch and set the correct
<sdk-version>
in thetiapp.xml
.Trying again now, using your latest commits!
Closing as a duplicate. If this is in error, please reopen.