[android] Video is crashing Error: while updating property 'rate' of a view managed by: RCTVideo

See original GitHub issue

Current behavior

it gives me error : Error: while updating property ‘rate’ of a view managed by: RCTVideo

Reproduction steps

it gives error every time we navigate to screen for playing video

Expected behavior

Video should play on android

Which player are you experiencing the problem on:

  • Android ExoPlayer

Video sample

I am picking video from local

Video code :

renderVideo() { return( <Video source={('./Measurements.mp4')} ref={(ref) => { this.player = ref }} controls = {false} fullscreen = {false} onLoadStart={() => {console.log("loading started")}} onLoad={() => {console.log("loading done")}} rate = {this.state.playerRate} style = {[styles.video]} /> ) }

my package.json

{ “name”: “abc”, “version”: “0.0.1”, “private”: true, “scripts”: { “start”: “node node_modules/react-native/local-cli/cli.js start”, “test”: “jest” }, “dependencies”: { “aws-amplify”: “^1.0.11”, “aws-amplify-react”: “^2.0.1”, “aws-amplify-react-native”: “^2.0.1”, “aws-appsync”: “^1.7.0”, “aws-appsync-react”: “^1.2.5”, “aws-sdk”: “^2.353.0”, “d3-shape”: “^1.2.2”, “es6-symbol”: “^3.1.1”, “google-libphonenumber”: “^3.1.14”, “graphql-tag”: “^2.10.0”, “i”: “^0.3.6”, “mobx”: “^4.8.0”, “mobx-react”: “^5.0.0”, “moment”: “^2.22.2”, “moment-range”: “^4.0.1”, “npm”: “^6.4.1”, “prop-types”: “^15.6.2”, “react”: “16.5.0”, “react-apollo”: “^2.2.4”, “react-art”: “^16.6.0”, “react-native”: “^0.57.4”, “react-native-chart-kit”: “^1.1.9”, “react-native-circular-progress”: “^1.0.1”, “react-native-elements”: “^1.0.0-beta6”, “react-native-i18n”: “^2.0.15”, “react-native-keyboard-aware-scroll-view”: “^0.7.2”, “react-native-linear-gradient”: “^2.4.2”, “react-native-multiple-picker”: “0.0.21”, “react-native-parallax-header”: “^1.0.6”, “react-native-phone-input”: “^0.2.1”, “react-native-popup-dialog”: “^0.16.3”, “react-native-progress”: “^3.5.0”, “react-native-progress-circle”: “^2.0.1”, “react-native-segmented-control-tab”: “^3.3.1”, “react-native-simple-dialogs”: “^0.4.1”, “react-native-slider”: “^0.11.0”, “react-native-svg”: “^6.4.1”, “react-native-svg-charts”: “^5.2.0”, “react-native-triangle”: “0.0.9”, “react-native-vector-icons”: “^6.1.0”, “react-native-video”: “^4.0.1”, “react-navigation”: “^2.14.2”, “rn-viewpager”: “^1.2.9” }, “devDependencies”: { “@babel/plugin-proposal-decorators”: “^7.1.2”, “@babel/runtime”: “^7.1.2”, “babel-jest”: “23.6.0”, “eslint-config-rallycoding”: “^3.2.0”, “jest”: “23.6.0”, “metro-react-native-babel-preset”: “^0.48.3”, “react-test-renderer”: “16.5.0” }, “jest”: { “preset”: “react-native” }, “rnpm”: { “assets”: [ “./assets/fonts/” ] } }

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Comments:6 (1 by maintainers)

github_iconTop GitHub Comments

5reactions
Brambillatorcommented, May 8, 2019

I have the same issue. With values from 0.1 to 2.0 it works, but gives me error when set to zero. Is there another way to pause the video?

Now the author has not maintained this problem, what should I do?

Just use the paused property instead of setting rate to zero.

Like this:

                        <Video
                            source={this.props.videSource}
                            rate={this.state.rate}
                            paused={this.state.paused} />
0reactions
MichaelHao25commented, May 8, 2019

@cobarx I’m facing this issue when I set 0 in Android, on iOS it works fine. What to do now?

Now the author has not maintained this problem, what should I do?

Read more comments on GitHub >

github_iconTop Results From Across the Web

[android] Video is crashing Error: while updating property 'rate ...
Current behavior it gives me error : Error: while updating property 'rate' of a view managed by: RCTVideo Reproduction steps it gives error ......
Read more >
React Native: error while updating property src of a view ...
On a brand new Expo app, I can reliably crash it on Android (iOS is fine) with the following code: export default function...
Read more >
react-native-video - npm
When playing an HLS live stream with a EXT-X-PROGRAM-DATE-TIME tag configured, then this property will contain the epoch value in msec.
Read more >
Unable to play on Android. Error while updating property 'src' of a ...
Error while updating property 'src' of a view managed by: RCTVideo. ... react-native-video ... My test app crashes immediately using the following code:...
Read more >
A Video Component for React Native - Morioh
See Updating for details. Version 4.0.0 now requires Android target SDK 26+ and Gradle 3 plugin in order to support ExoPlayer 2.9.0.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found