expo / expo/snack

Error with Reanimated v2

Open
#140 1 comment 0 reactions 0 assignees View on GitHub
runtime
Dominant language
TypeScript
Stars
508
Forks
178
Avg merge
5h 7m
Merged PRs (30d)
5

Description

### Summary

Even creating a blank project where I just `import Animated from 'react-native-reanimated';` causes an error on Android ("Uncaught Error: Animated node with ID 2 already exists").
This only happen on Android, and only on Snack, if I build the same project on my local machine, I don't seem to have any problem.

### What platform(s) does this occur on?

Android

### SDK Version

v41.0.0

### Reproducible demo or steps to reproduce from a blank project

Here's the Snack: https://snack.expo.io/@ricvail/reanimated-error
Sometimes it seems that it works on the first try (or first couple of tries).
I tried on my Android phone (where expo was already installed, and it gave immediately the error), on my sister's android phone (freshly installed Expo, worked on the first try, I killed expo, reopened it, and it started crashing), and on my own phone again after clearing Expo's cache (again worked on first try).
On my iPad I have no such problem.

Also, most of the times the Expo app actually just crashes without giving any error. But when it does display the error, it's the one mentioned above.

Contributor guide

Open the contributing guide

Research direction

Start with the linked Snack and reproduce the failure in Expo on Android using SDK v41.0.0, importing react-native-reanimated in a blank project. Compare repeated launches, cache-cleared launches, local builds, and iPad behavior. Done means the Snack no longer reports duplicate animated node IDs or crashes on Android.

Written by the indexing model from the issue text.

Assessment

Tech stack
react-native
Domain
mobile-dev
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
30/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.