Exception thrown while executing UI block: *** -[__NSPlaceholderArray initWithObjects:count:]: attempt to insert nil object from objects[0]
See original GitHub issueReproduction
Issue happens only when running on iOS
We have a screen where we show an image. We use modified version of this example. Modified version can be found here.
Issue happens when one navigate away from a screen where the touch handler is used and then navigate back to it using react-navigationβs navigation.goBack();
. See the output below.
Same happens if we use the imageViewer example without modifining it.
This issue doesnβt happen on Android.
Issue screenshot - iOS
Console log
Output of node -v && npm -v && npm ls --prod --depth=1
v11.6.0
6.5.0
capmo@0.0.1 /Users/miodrag/Desktop/pave/mobileapp
βββ¬ @ambassify/fetch-retried@1.1.0
β βββ @ambassify/fetch@1.0.3
βββ¬ @nozbe/watermelondb@0.8.0
β βββ rambdax@0.21.0
β βββ rxjs@6.3.2 deduped
β βββ rxjs-compat@6.3.3
β βββ sql-escape-string@1.1.0
βββ¬ @nozbe/with-observables@1.0.1
β βββ rxjs@6.3.2 deduped
βββ¬ better-queue@3.8.10
β βββ better-queue-memory@1.0.3 deduped
β βββ node-eta@0.9.0
β βββ uuid@3.3.2 deduped
βββ better-queue-memory@1.0.3
βββ¬ color@3.1.0
β βββ color-convert@1.9.3
β βββ color-string@1.5.3
βββ date-fns@1.29.0
βββ¬ es6-symbol@3.1.1
β βββ d@1.0.0
β βββ es5-ext@0.10.46
βββ events@2.1.0
βββ¬ extract-files@2.1.1
β βββ @babel/runtime@7.1.2
βββ¬ formik@1.2.0
β βββ create-react-context@0.2.3
β βββ deepmerge@2.1.1
β βββ hoist-non-react-statics@2.5.5
β βββ lodash.clonedeep@4.5.0
β βββ lodash.topath@4.5.2
β βββ prop-types@15.6.2 deduped
β βββ UNMET PEER DEPENDENCY react@^0.14.0 || ^15.0.0 || ^16.0.0
β βββ react-fast-compare@1.0.0
β βββ tslib@1.9.3
β βββ warning@3.0.0
βββ lodash@4.17.11
βββ moment@2.22.2
βββ¬ moment-timezone@0.5.21
β βββ moment@2.22.2 deduped
βββ¬ prop-types@15.6.2
β βββ loose-envify@1.4.0
β βββ object-assign@4.1.1
βββ ramda@0.25.0
βββ¬ UNMET PEER DEPENDENCY react@16.6.0-alpha.8af6728
β βββ loose-envify@1.4.0 deduped
β βββ object-assign@4.1.1 deduped
β βββ prop-types@15.6.2 deduped
β βββ scheduler@0.10.0
βββ¬ UNMET PEER DEPENDENCY react-native@0.57.4
β βββ @babel/runtime@7.1.2 deduped
β βββ absolute-path@0.0.0
β βββ art@0.10.3
β βββ base64-js@1.3.0
β βββ chalk@1.1.3
β βββ commander@2.17.1
β βββ compression@1.7.3
β βββ connect@3.6.6
β βββ create-react-class@15.6.3
β βββ debug@2.6.9
β βββ denodeify@1.2.1
β βββ envinfo@5.10.0
β βββ errorhandler@1.5.0
β βββ escape-string-regexp@1.0.5
β βββ event-target-shim@1.1.1
β βββ fbjs@1.0.0
β βββ fbjs-scripts@0.8.3
β βββ fs-extra@1.0.0
β βββ glob@7.1.3
β βββ graceful-fs@4.1.11
β βββ inquirer@3.3.0
β βββ lodash@4.17.11 deduped
β βββ metro@0.48.3
β βββ metro-babel-register@0.48.3
β βββ metro-core@0.48.3
β βββ metro-memory-fs@0.48.3
β βββ mime@1.6.0
β βββ minimist@1.2.0
β βββ mkdirp@0.5.1
β βββ morgan@1.9.0
β βββ node-fetch@2.2.0
β βββ node-notifier@5.2.1
β βββ npmlog@2.0.4
β βββ opn@3.0.3
β βββ optimist@0.6.1
β βββ plist@3.0.1
β βββ pretty-format@4.3.1
β βββ promise@7.3.1
β βββ prop-types@15.6.2 deduped
β βββ react-clone-referenced-element@1.0.1
β βββ react-devtools-core@3.4.2
β βββ react-timer-mixin@0.13.4
β βββ regenerator-runtime@0.11.1
β βββ rimraf@2.6.2
β βββ semver@5.5.1
β βββ serve-static@1.13.2
β βββ shell-quote@1.6.1
β βββ stacktrace-parser@0.1.4
β βββ ws@1.1.5
β βββ xcode@1.0.0
β βββ xmldoc@0.4.0
β βββ yargs@9.0.1
βββ¬ react-native-datepicker@1.7.2
β βββ moment@2.22.2 deduped
βββ react-native-elevated-view@0.0.6
βββ¬ react-native-gesture-handler@1.0.7
β βββ hoist-non-react-statics@2.5.5 deduped
β βββ invariant@2.2.4
β βββ prop-types@15.6.2 deduped
βββ react-native-image-pan-zoom@2.1.10
βββ react-native-image-picker@0.26.10
βββ¬ react-native-image-zoom-viewer@2.2.19
β βββ react-native-image-pan-zoom@2.1.10 deduped
βββ¬ react-native-keyboard-aware-scroll-view@0.7.4
β βββ prop-types@15.6.2 deduped
β βββ react-native-iphone-x-helper@1.2.0
βββ¬ react-native-modal@6.5.0
β βββ prop-types@15.6.2 deduped
β βββ react-native-animatable@1.3.0
βββ¬ react-native-modal-dropdown@0.6.2
β βββ prop-types@15.6.2 deduped
βββ¬ react-native-paper@2.0.1
β βββ @callstack/react-theme-provider@1.0.3
β βββ color@2.0.1
β βββ create-react-context@0.2.3 deduped
β βββ hoist-non-react-statics@2.5.5 deduped
β βββ UNMET PEER DEPENDENCY react@^15.3.0 || ^16.0.0
β βββ react-lifecycles-compat@3.0.4
βββ¬ react-native-pdf@5.0.9
β βββ crypto-js@3.1.9-1
β βββ prop-types@15.6.2 deduped
βββ react-native-reanimated@1.0.0-alpha.9
βββ react-native-remote-svg@1.3.0
βββ react-native-responsive-screen@1.1.10
βββ react-native-screens@1.0.0-alpha.12
βββ react-native-splash-screen@3.1.1
βββ react-native-status-bar-height@2.1.0
βββ react-native-typography@1.4.0
βββ¬ react-native-vector-icons@5.0.0
β βββ lodash@4.17.11 deduped
β βββ prop-types@15.6.2 deduped
β βββ yargs@8.0.2
βββ¬ react-navigation@2.12.1
β βββ clamp@1.0.1
β βββ create-react-context@0.2.3 deduped
β βββ hoist-non-react-statics@2.5.5 deduped
β βββ path-to-regexp@1.7.0
β βββ query-string@6.1.0
β βββ UNMET PEER DEPENDENCY react@^0.14.0 || ^15.0.0 || ^16.0.0
β βββ react-lifecycles-compat@3.0.4 deduped
β βββ react-native-safe-area-view@0.9.0
β βββ react-navigation-deprecated-tab-navigator@1.3.0
β βββ react-navigation-drawer@0.5.0
β βββ react-navigation-stack@0.2.3
β βββ react-navigation-tabs@0.6.0
βββ¬ react-validator-prop-types@1.1.0
β βββ validator@3.43.0
βββ¬ recompose@0.30.0
β βββ @babel/runtime@7.1.2 deduped
β βββ change-emitter@0.1.6
β βββ fbjs@0.8.17
β βββ hoist-non-react-statics@2.5.5 deduped
β βββ react-lifecycles-compat@3.0.4 deduped
β βββ symbol-observable@1.2.0
βββ¬ rn-fetch-blob@0.10.13
β βββ base-64@0.1.0
β βββ glob@7.0.6
βββ¬ rxjs@6.3.2
β βββ tslib@1.9.3 deduped
βββ¬ styled-components@3.4.9
β βββ buffer@5.2.1
β βββ css-to-react-native@2.2.2
β βββ fbjs@0.8.17 deduped
β βββ hoist-non-react-statics@2.5.5 deduped
β βββ prop-types@15.6.2 deduped
β βββ react-is@16.5.2
β βββ stylis@3.5.3
β βββ stylis-rule-sheet@0.0.10
β βββ supports-color@3.2.3
βββ¬ util@0.11.0
β βββ inherits@2.0.3
βββ uuid@3.3.2
npm ERR! peer dep missing: react@^16.5.0, required by @nozbe/watermelondb@0.8.0
npm ERR! peer dep missing: react@^16.4.2, required by @nozbe/with-observables@1.0.1
npm ERR! peer dep missing: react@>=15, required by formik@1.2.0
npm ERR! peer dep missing: react@> 15.0.0, required by react-native-gesture-handler@1.0.7
npm ERR! peer dep missing: react@16.0.0-alpha.6, required by react-native-reanimated@1.0.0-alpha.9
npm ERR! peer dep missing: react@>=15, required by react-native-remote-svg@1.3.0
npm ERR! peer dep missing: react@>=16.0.0, required by react-native-testing-library@1.5.0
npm ERR! peer dep missing: react@^16.0.0, required by react-test-renderer@16.4.1
npm ERR! peer dep missing: react@^0.14.0 || ^15.0.0 || ^16.0.0, required by recompose@0.30.0
npm ERR! peer dep missing: react@>= 0.14.0 < 17.0.0-0, required by styled-components@3.4.9
npm ERR! peer dep missing: react-native@^0.56.0, required by @nozbe/watermelondb@0.8.0
npm ERR! peer dep missing: react-native@^0.44.1, required by react-native-reanimated@1.0.0-alpha.9
npm ERR! peer dep missing: react@^0.14.0 || ^15.0.0 || ^16.0.0, required by create-react-context@0.2.3
npm ERR! peer dep missing: react@^15.3.0 || ^16.0.0, required by @callstack/react-theme-provider@1.0.3
npm ERR! peer dep missing: react@^0.14.0 || ^15.0.0 || ^16.0.0, required by create-react-context@0.2.3
npm ERR! peer dep missing: react@^0.14.0 || ^15.0.0 || ^16.0.0, required by create-react-context@0.2.3
npm ERR! peer dep missing: react@^0.14.0 || ^15.0.0 || ^16.0.0, required by create-react-context@0.2.3
Issue Analytics
- State:
- Created 5 years ago
- Reactions:13
- Comments:11 (2 by maintainers)
Top Results From Across the Web
attempt to insert nil object from objects[0]' - Stack Overflow
I am working with UITableview i am displaying image, title,date and location name on tableview cell.When iΒ ...
Read more >iOS : React Native: Exception thrown while executing UI block
iOS : React Native: Exception thrown while executing UI block [ Beautify Your Computer : https://www.hows.tech/p/recommended.html ] iOSΒ ...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Hey folks π We decided to close this issue because we were not able to reproduce it for a long period of time. If anyone of you will be able to provide a minimal reproduction of this issue, we will reopen it and work on it. Have a nice day! π
Iβve seen this bug a number of times (but it doesnβt cause a crash). I believe it occurs when a component using an
Animated.Value
is unmounted before theAnimated.Value
update is propagated to the component.I notice it the most when a pan gesture recognizer updates the location of a component and then that component unmounts while moving it around.
If I had to guess, I would say this issue feels a little like forgetting to call
window.clearTimeout
oncomponentWillUnmount
β maybe somewhere in the native code, pending callbacks need to be cleared when a UIView is detached/unmounted?