React-native-reanimated: Exception thrown while executing UI block: 'parentNode' is a required parameter

Created on 6 Oct 2020  Β·  28Comments  Β·  Source: software-mansion/react-native-reanimated

Description

While working on React Native Gallery Toolkit, I've got this error.

I'm not sure how to reproduce it in some playground, not sure what exactly causes it:

Exception thrown while executing UI block: 'parentNode' is a required parameter

__44-[RCTUIManager flushUIBlocksWithCompletion:]_block_invoke
    RCTUIManager.m:1192
-[REANodesManager performOperations]
-[REANodesManager onAnimationFrame:]
CA::Display::DisplayLink::dispatch_items(unsigned long long, unsigned long long, unsigned long long)
display_timer_callback(__CFMachPort*, void*, long, void*)
__CFMachPortPerform
__CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE1_PERFORM_FUNCTION__
__CFRunLoopDoSource1
__CFRunLoopRun
CFRunLoopRunSpecific
GSEventRunModal
UIApplicationMain
main
start
0x0

Screenshots

image

Steps To Reproduce

  1. Clone this repo https://github.com/terrysahaidak/react-native-gallery-toolkit
  2. Switch to tr-lightbox branch and run the Example project
  3. Navigate to Lightbox => Shared Element Transition
  4. Open/close image a few times in a row.

The error might occur after a few reloading or immediately.

Expected behavior

Should not throw the error.

Actual behavior

Throws an error but still works if I just close it.

Snack or minimal code example

  1. Clone this repo https://github.com/terrysahaidak/react-native-gallery-toolkit
  2. Switch to tr-lightbox branch and run the Example project

Package versions

  • React: 16.13.1
  • React Native: 0.63.2
  • React Native Reanimated: 2.0.0-alpha.7
🏠 Reanimated2 🐞 Bug

Most helpful comment

Hello, facing the same problem in Alpha 8. I thought it was solved but it’s not 😒

All 28 comments

Just chiming in here to say that I also started seeing this on 2.0.0-alpha.7 when attempting to run a portal-based image transition across the screen and fast-refreshing several times in a row. I'll try to find a reliable way to reproduce, but for me it seemed to only happen when the transitions were happening in rapid succession.

Also having exact same issue

facing the same issue

Same issue goes for me, reanimated version 2.0.0-alpha.7.

The fix here is to disable TurboModules for all the modules except Reanimated. Its landed in master, should be available with the new release. I will keep this issue open until.

The fix here is to disable TurboModules for all the modules except Reanimated. Its landed in master, should be available with the new release. I will keep this issue open until.

Do you know when the next reanimated alpha 8 will be released ?

You can apply this patch in the meantime:
https://github.com/rainbow-me/rainbow/blob/develop/patches/react-native%2B0.63.2.patch

Also, make sure to remove this line
https://github.com/software-mansion-labs/reanimated-2-playground/blob/master/ios/Reanimated2Playground/AppDelegate.mm#L51

Great !!! Thanks you very much @terrysahaidak it is working :-)

I downgraded the React-native version to 63.2 and commented out the IOS settings, but the error is still the same.

As alpha 8 is out you can try using it.

I will use it for a few days and let know if it's fixed with alpha.8

facing the same problem on alpha.8 but don't know how to reproduce it πŸ€·πŸ»β€β™‚οΈ

facing the same problem on alpha.8 but don't know how to reproduce it πŸ€·πŸ»β€β™‚οΈ

do you use expo? did you try to clean and rebuilid the project?

Having the same issue with RN 0.61.2 and "react-native-reanimated": "^1.13.1"

Having the same issue with RN 0.61.2 and "react-native-reanimated": "^1.13.1"

could you create reproducing example?

@terrysahaidak Honestly, probably not, I'm not sure why it started to break, but I did not use to have issues with it. But it is engrained in my app repo, not sure how I could reproduce that. I quickly tried to install react-native-reanimated v: alpha8 but couldn't run pod install, it was telling me: [!] Unable to find a specification for React-callinvoker depended upon by RNReanimated

facing the same problem on alpha.8 but don't know how to reproduce it πŸ€·πŸ»β€β™‚οΈ

do you use expo? did you try to clean and rebuilid the project?

No, I'm not using expo

Hello, facing the same problem in Alpha 8. I thought it was solved but it’s not 😒

I'm also facing this issue with Alpha 8

Just updated to RN 0.63.3 and tried all different kinds of versions of react-native-reanimated: 1.3.0, 1.13.1, 2.0.0-alpha8 and none worked.

@terrysahaidak Your links you posted above do not work.

alpha.8 has this solved. please make sure to undo all the installation guide things from previous versions and clear the cache before the build.

This is reproduced on alpha.9

In my case, I fixed this issue by converting other combined use cases using react-native Animated API to Reanimated 2 API.
But it seems to don't fix completely.

Still got this issue :
image

Hello everyone!
I've noticed some activity here, some people still seem to have this problem.
As this issue is closed I think the best thing you can do if you're facing this is either open a new one or reopen this one.

With that said, posting a screen with this error occurring or just saying that you have this problem, gives us nothing. If you decide to reopen the issue/open a new issue connected to this one, please provide a reproducing example and some more information regarding the circumstances in which this happens(is it a fresh rn app, and if it's not then what's the background, like did you move from rea 1 to rea2 or what, what are packages modules, stuff like that).

Thank you for the cooperation, if there's a problem I'm happy to help! ✌️

hey @mym0404 and @JB-CHAUVIN – any change you can share your code for us to try and reproduce the crash? If not maybe you can describe at what stage the crash happens, e.g., at app startup / when starting some animation / when instantiating some components on the screen.

@kmagiera The issue was gone after start new metro server and application. I don't know the exact reason. But sometimes, it happened at device orientation change(portrait -> landscape). I am not paying attention to this issue now because it is not reproduced after that.
Thank you for your concerns

Just submitted #1501 which addresses the issue we think was causing the crash. If some of you are still experiencing it can you please try out this patch to see if it resolves the issue for you?

Was this page helpful?
0 / 5 - 0 ratings

Related issues

wasim-abuzaher picture wasim-abuzaher  Β·  3Comments

mldb picture mldb  Β·  3Comments

robertgonzales picture robertgonzales  Β·  3Comments

ArsalanCsquare picture ArsalanCsquare  Β·  3Comments

bjartebore picture bjartebore  Β·  3Comments