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

Error on AnimatedValue.js file when it tries to call flush #25210

Closed
iagormoraes opened this issue Jun 10, 2019 · 7 comments
Closed

Error on AnimatedValue.js file when it tries to call flush #25210

iagormoraes opened this issue Jun 10, 2019 · 7 comments
Labels
API: Animated Bug Flow Stale There has been a lack of activity on this issue and it may be closed soon.

Comments

@iagormoraes
Copy link

iagormoraes commented Jun 10, 2019

The AnimatedValue.js throws an error on line 58 when node.__getChildren().forEach(findAnimatedStyles); is called on _flush function sometimes.

React Native version: 0.58.3

Steps To Reproduce

1 - create variable with Animated.Value
2 - update the value

Describe what you expected to happen:
Animations work properly.

Snack, code example, or link to a repository:

The error happens in node_modules/react-native/Libraries/Animated/src/nodes/AnimatedValue.js in findAnimatedStyles at line 58:28:

function _flush(rootNode: AnimatedValue): void {
  const animatedStyles = new Set();
  function findAnimatedStyles(node) {
    /* $FlowFixMe(>=0.68.0 site=react_native_fb) This comment suppresses an
     * error found when Flow v0.68 was deployed. To see the error delete this
     * comment and run Flow. */
    if (typeof node.update === 'function') {
      animatedStyles.add(node);
    } else {
      node.__getChildren().forEach(findAnimatedStyles);
    }
  }
  findAnimatedStyles(rootNode);
  /* $FlowFixMe */
  animatedStyles.forEach(animatedStyle => animatedStyle.update());
}

Throws TypeError: s.__getChildren().forEach is not a function. (In 's.__getChildren().forEach(t)', 's.__getChildren().forEach' is undefined)

Error screenshot:

Screen Shot 2019-06-10 at 09 21 26

@iagormoraes iagormoraes changed the title flowError on AnimatedValue.js file flow's error on AnimatedValue.js file Jun 10, 2019
@iagormoraes iagormoraes changed the title flow's error on AnimatedValue.js file Error on AnimatedValue.js file when it tries to call flush Jun 10, 2019
@stale
Copy link

stale bot commented Sep 8, 2019

Hey there, it looks like there has been no activity on this issue recently. Has the issue been fixed, or does it still require the community's attention? This issue may be closed if no further activity occurs. You may also label this issue as a "Discussion" or add it to the "Backlog" and I will leave it open. Thank you for your contributions.

@stale stale bot added the Stale There has been a lack of activity on this issue and it may be closed soon. label Sep 8, 2019
@radik
Copy link

radik commented Sep 12, 2019

I have the same issue. I could not say exactly how to reproduce it. I got an issue report from Crashlytics. Some of my users faced it.
Android 7
Phone Samsung Galaxy S7 edge

@stale stale bot removed the Stale There has been a lack of activity on this issue and it may be closed soon. label Sep 12, 2019
@stale
Copy link

stale bot commented Dec 11, 2019

Hey there, it looks like there has been no activity on this issue recently. Has the issue been fixed, or does it still require the community's attention? This issue may be closed if no further activity occurs. You may also label this issue as a "Discussion" or add it to the "Backlog" and I will leave it open. Thank you for your contributions.

@stale stale bot added the Stale There has been a lack of activity on this issue and it may be closed soon. label Dec 11, 2019
@haorh
Copy link

haorh commented Dec 11, 2019

Faced same issue with user of Samsung's Galaxy S7 SM-G930F. Reported by Bugsnag
React-native 0.59.9.
Unable to reproduce. Error occurred after Splash Activity.

@stale stale bot removed the Stale There has been a lack of activity on this issue and it may be closed soon. label Dec 11, 2019
@sam1463
Copy link

sam1463 commented Jan 8, 2020

Also seeing this, occurring on Samsung SM-G930F on Android 7.0 on react-native 0.61.5

@stale
Copy link

stale bot commented Apr 7, 2020

Hey there, it looks like there has been no activity on this issue recently. Has the issue been fixed, or does it still require the community's attention? This issue may be closed if no further activity occurs. You may also label this issue as a "Discussion" or add it to the "Backlog" and I will leave it open. Thank you for your contributions.

@stale stale bot added the Stale There has been a lack of activity on this issue and it may be closed soon. label Apr 7, 2020
@stale
Copy link

stale bot commented Apr 14, 2020

Closing this issue after a prolonged period of inactivity. If this issue is still present in the latest release, please feel free to create a new issue with up-to-date information.

@stale stale bot closed this as completed Apr 14, 2020
@facebook facebook locked as resolved and limited conversation to collaborators Apr 15, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
API: Animated Bug Flow Stale There has been a lack of activity on this issue and it may be closed soon.
Projects
None yet
Development

No branches or pull requests

5 participants