react-native-shared-element icon indicating copy to clipboard operation
react-native-shared-element copied to clipboard

Issue with methodQueue Setter in v0.9.0-rc0 of react-native-shared-elements

Open Ceck-15 opened this issue 10 months ago • 7 comments

Hello,

I recently encountered an issue with corner radii and resolved it by switching to the pre-release version (v0.9.0-rc0) of react-native-shared-elements. However, after updating, I'm now facing the following error:

RNSharedElementTransition has no setter or ivar for its methodQueue, which is not permitted. You must either @synthesize the methodQueue property, or provide your own setter method.

-[RCTTurboModuleManager _createAndSetUpObjCModule:moduleName:moduleId:] RCTTurboModuleManager.mm:746 __71-[RCTTurboModuleManager _provideObjCModule:moduleHolder:shouldPerfLog:]_block_invoke __RCTUnsafeExecuteOnMainQueueSync_block_invoke C05E486D-81F2-367E-9CE1-E14573C4C268 C05E486D-81F2-367E-9CE1-E14573C4C268 C05E486D-81F2-367E-9CE1-E14573C4C268 C05E486D-81F2-367E-9CE1-E14573C4C268 _dispatch_main_queue_callback_4CF 0013A8B1-2524-3534-B5BA-681AAF18C798 0013A8B1-2524-3534-B5BA-681AAF18C798 CFRunLoopRunSpecific GSEventRunModal 8CC54497-F7EC-3903-AE5A-A274047C0CF1 UIApplicationMain main A770FF8C-8FB9-3E03-85FE-7F26DB36812B

For context, here are my current dependency versions:

expo: ~52.0.36
react: 18.3.1
react-native: 0.76.7
react-native-shared-element: ^0.9.0-rc0
react-navigation-shared-element: ^3.1.3

I attempted to address the error by adding: @synthesize methodQueue = _methodQueue;

at the top of the implementation file, but unfortunately, it did not resolve the issue. I am using EAS Build for this project. Any guidance or recommendations on how to resolve this would be greatly appreciated.

Ceck-15 avatar Mar 12 '25 17:03 Ceck-15

Hey! Thanks for opening the issue. The issue doesn't seem to contain a link to a repro (a snack.expo.dev link or link to a GitHub repo under your username).

Can you provide a minimal repro which demonstrates the issue? A repro will help us debug the issue faster. Please try to keep the repro as small as possible and make sure that we can run it without additional setup.

github-actions[bot] avatar Mar 12 '25 17:03 github-actions[bot]

Having this issue as well

du5rte avatar Mar 13 '25 18:03 du5rte

Having this issue as well

lvothnrv avatar Mar 20 '25 17:03 lvothnrv

same issue coming in latest "react-native-shared-element": "^0.9.0-rc0", the issue in this class

@implementation RNSharedElementTransition { NSArray* _items; UIView* _outerStyleView; UIView* _innerClipView; UIImageView* _primaryImageView; UIImageView* _secondaryImageView; BOOL _reactFrameSet; BOOL _initialLayoutPassCompleted; int _initialVisibleAncestorIndex; }

and in. this file ios/RNSharedElementTransition.m

zeeshan6 avatar Mar 21 '25 16:03 zeeshan6

Any updates here?

solonik1 avatar May 11 '25 16:05 solonik1

I'm using react-native 0.79.2. Still has this issue. Can anyone tell me how to do temporary fix? Thanks

tomcheung1208 avatar Jun 03 '25 06:06 tomcheung1208

in order to fix the issue replace in RNSharedElementTransitionManager.m following code:

- (dispatch_queue_t)methodQueue
{
  return self.bridge.uiManager.methodQueue;
}

with this:

- (dispatch_queue_t)methodQueue {
  return dispatch_get_main_queue();
}

Vadko avatar Jun 04 '25 20:06 Vadko