bartgryszko / react-native-circular-progress

React Native component for creating animated, circular progress with ReactART
MIT License
2.12k stars 423 forks source link

backgroundColor not working on android #214

Open rafaelbpa opened 4 years ago

rafaelbpa commented 4 years ago

Hi,

I'm trying to run a minimal example, but when I set the backgroundColor on android it crashes without any error log. The app just closes itself.

I am using react-native 0.61.2 react-native-svg ^9.7.1 (also tried to update to latest one, 9.12.0, but nothing changed) react-native-circular-progress 1.3.2

On iOS works just fine. The error happens on the device and simulator.

Any ideas about what could be?

Edit: Created a small sample (blank project w/ react-native-circular-progress). As I said, works on iOS, but not on android. https://github.com/rafaelbpa/test-react-native-circular-progress

rafaelbpa commented 4 years ago

After the new update of the lib (1.3.3) the bug was gone. I guess we can close this.

markusl commented 4 years ago

Thanks for the follow-up!

BalalRaza commented 4 years ago

I checked with the new update (1.3.3), it didn't work. Bug is still there and my app crashed with the same error. I did try on my friend's system as well, same issue. I dug deeper and found the issue was not solved completely, although in the right direction. I've created a PR for that: #217

BalalRaza commented 4 years ago

Also, related issue: #213

perrosnk commented 4 years ago

Any updates? Still not working on 1.3.4

rafaelbpa commented 4 years ago

If this is not working, can we reopen this? @markusl

markusl commented 4 years ago

@rafaelbpa I reopened the issue. Unfortunately I'm unable to check this with Android at the moment. Any pull requests are appreciated :)

BalalRaza commented 4 years ago

@perrosnk Can you describe your issue a little bit? What error is occuring? I am currently using this library and I am facing no further issues after 1.3.4. I would like to fix this in case its broken for others.

rafaelbpa commented 4 years ago

@BalalRaza and @perrosnk can you try something for me? Can you install the react-native-gesture-handler (https://github.com/kmagiera/react-native-gesture-handler) on your project and tell me if it works?

I updated my original sample to the latest version (1.3.4) and installed react-native-gesture-handler and it is working here on Android and iOS.

You can also clone and test my sample: https://github.com/rafaelbpa/test-react-native-circular-progress

perrosnk commented 4 years ago

I am already using react-native-gesture-handler as I am using react-navigation.

I don't know if that helps, but that's my dependencies list

    "dependencies": {
        "@apollo/react-hooks": "^3.1.3",
        "@react-native-community/masked-view": "^0.1.5",
        "@react-native-community/netinfo": "^4.4.0",
        "@react-native-firebase/admob": "^6.0.2",
        "@react-native-firebase/analytics": "^6.0.2",
        "@react-native-firebase/app": "^6.0.2",
        "@react-native-firebase/auth": "^6.0.2",
        "@react-native-firebase/messaging": "^6.0.2",
        "@react-native-firebase/storage": "^6.0.2",
        "@react-navigation/bottom-tabs": "^5.0.0-alpha.22",
        "@react-navigation/core": "^5.0.0-alpha.23",
        "@react-navigation/native": "^5.0.0-alpha.16",
        "@react-navigation/stack": "^5.0.0-alpha.37",
        "apollo-boost": "^0.4.4",
        "apollo-link-ws": "^1.0.19",
        "apsl-react-native-button": "^3.1.1",
        "graphql": "^14.5.8",
        "graphql-tag": "^2.10.1",
        "lodash": "^4.17.15",
        "mobx": "^5.15.0",
        "mobx-react": "^5.4.4",
        "moment": "^2.24.0",
        "numbro": "^2.1.2",
        "prop-types": "^15.7.2",
        "react": "16.9.0",
        "react-apollo": "^3.1.3",
        "react-dom": "^16.10.2",
        "react-native": "0.61.2",
        "react-native-action-button": "^2.8.5",
        "react-native-branch": "^4.2.1",
        "react-native-button": "^2.4.0",
        "react-native-circular-progress": "^1.3.4",
        "react-native-code-push": "^5.7.0",
        "react-native-communications": "^2.2.1",
        "react-native-contacts": "^5.0.4",
        "react-native-country-picker-modal": "^1.7.2",
        "react-native-device-info": "^4.0.1",
        "react-native-fbsdk": "^1.0.4",
        "react-native-gesture-handler": "^1.5.0",
        "react-native-image-picker": "^1.1.0",
        "react-native-image-zoom-viewer": "^2.2.26",
        "react-native-keyboard-spacer": "^0.4.1",
        "react-native-linear-gradient": "^2.5.6",
        "react-native-localize": "^1.3.1",
        "react-native-material-ripple": "^0.9.1",
        "react-native-modal": "^11.4.0",
        "react-native-permissions": "^2.0.2",
        "react-native-radio-buttons": "^1.0.0",
        "react-native-reanimated": "^1.4.0",
        "react-native-safe-area-context": "^0.6.0",
        "react-native-safe-area-view": "^1.0.0",
        "react-native-screens": "^2.0.0-alpha.8",
        "react-native-svg": "^9.12.0",
        "react-native-vector-icons": "^6.6.0",
        "react-navigation-header-buttons": "^3.0.4",
        "recompose": "^0.30.0",
        "rn-fetch-blob": "^0.11.2",
        "subscriptions-transport-ws": "^0.9.16"
    },
BalalRaza commented 4 years ago

@BalalRaza and @perrosnk can you try something for me? Can you install the react-native-gesture-handler (https://github.com/kmagiera/react-native-gesture-handler) on your project and tell me if it works?

I too have it in my project. It works without any issues.

michaelgriss commented 4 years ago

I have the same issue. Using backgroundColor causes my Android emulator to crash, but it works as expected on an IoS device. I updated to 1.3.4 and I still have the same issue. I can't update react-native-svg as later versions aren't supported by Expo. My dependencies:

"dependencies": { "@react-native-community/datetimepicker": "^2.1.0", "expo": "^35.0.0", "expo-ads-admob": "^7.0.0", "expo-av": "^7.0.1", "expo-linear-gradient": "^7.0.1", "expo-permissions": "^7.0.0", "expo-sqlite": "^7.0.0", "react": "16.8.3", "react-dom": "16.8.3", "react-native": "https://github.com/expo/react-native/archive/sdk-35.0.0.tar.gz", "react-native-circular-progress": "^1.3.4", "react-native-gesture-handler": "~1.3.0", "react-native-reanimated": "^1.2.0", "react-native-svg": "~9.9.2", "react-native-web": "^0.11.7", "react-navigation": "^4.0.10", "react-navigation-animated-switch": "^0.3.2", "react-navigation-drawer": "^2.3.1", "react-navigation-header-buttons": "^3.0.3", "react-navigation-stack": "^1.9.0", "react-navigation-tabs": "^2.5.5", "react-redux": "^7.1.1", "redux": "^4.0.4", "redux-thunk": "^2.3.0" },

Any ideas or workarounds?

hari7priya commented 4 years ago

This seems to be fixed in 1.3.4. App was crashing on Android when BackgroundColor is there. However, upgrade to 1.3.4 fixed it. Thanks a lot!