Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Using SharedValue.set() fails with 'Tried to synchronously call a non-worklet anonymous function on the UI thread.' when mixing with with* helpers #6613

Open
chrisnojima opened this issue Oct 18, 2024 · 4 comments
Assignees
Labels
Platform: iOS This issue is specific to iOS Repro provided A reproduction with a snippet of code, snack or repo is provided

Comments

@chrisnojima
Copy link

Description

I'm switching my code from using the old style opacity.value = withDelay... to opacity.set(withDelay... but this fails.
Instead it only works if i use the callback form opacity.set(() => withDelay.... Unclear if this is by design but it was definitely confusing

Steps to reproduce

  1. Update to 3.16.0
  2. use .set with a withDelay (style) helper
  3. see a red box error

Snack or a link to a repository

sorry

Reanimated version

3.16.0

React Native version

0.75.4

Platforms

iOS

JavaScript runtime

None

Workflow

None

Architecture

Paper (Old Architecture)

Build type

None

Device

None

Device model

No response

Acknowledgements

Yes

@github-actions github-actions bot added Platform: iOS This issue is specific to iOS Missing repro This issue need minimum repro scenario labels Oct 18, 2024
@contactsimonwilson
Copy link

I'm getting the same thing

@g-siedlecki
Copy link

I'm also wondering if this is a bug.
I created a minimal reproduction repo: https://github.com/g-siedlecki/ReanimatedRepro
Running React Native 0.75.4 and Reanimated 3.16.1. Tested on both iOS and Android.

@github-actions github-actions bot added Repro provided A reproduction with a snippet of code, snack or repo is provided and removed Missing repro This issue need minimum repro scenario labels Nov 5, 2024
@tjzel tjzel self-assigned this Nov 5, 2024
@tjzel
Copy link
Collaborator

tjzel commented Nov 5, 2024

This shouldn't happen. I'll investigate.

@github-actions github-actions bot added Missing repro This issue need minimum repro scenario and removed Repro provided A reproduction with a snippet of code, snack or repo is provided labels Nov 5, 2024

This comment was marked as spam.

@tjzel tjzel added Repro provided A reproduction with a snippet of code, snack or repo is provided and removed Missing repro This issue need minimum repro scenario labels Nov 5, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Platform: iOS This issue is specific to iOS Repro provided A reproduction with a snippet of code, snack or repo is provided
Projects
None yet
Development

No branches or pull requests

4 participants