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

Execution failed for task ':app:preDebugBuild' #158

Closed
devautor opened this issue Feb 19, 2019 · 8 comments
Closed

Execution failed for task ':app:preDebugBuild' #158

devautor opened this issue Feb 19, 2019 · 8 comments

Comments

@devautor
Copy link

I have downloaded the example code from this repo, deleted ios folder to mitigate ios package linking specific error (on Windows), and then I could successfully use react-native link react-native-razorpay. In android/app/build.gradle, this sets implementation project(':react-native-razorpay'), while docs say to do compile project(':react-native-razorpay') in manual steps.

Issue: On running react-native run-android I am getting following error threads, which I could not fix myself. I did try a day worth of combinations. I am getting the same thing irrespective of using the example folder (with deleted ios folder) or creating a new one with react-native init .... Both are behaving the same as reported below. I tried both of these following changes in build.gradle in both types of projects. Errors are:

With implementation project(':react-native-razorpay'):

> Task :app:preDebugBuild FAILED

FAILURE: Build failed with an exception.

* What went wrong:
Execution failed for task ':app:preDebugBuild'.
> Android dependency 'com.facebook.fresco:imagepipeline-base:1.10.0' is set to compileOnly/provided which is not supported

With compile project(':react-native-razorpay'):

> Task :app:preDebugBuild FAILED

FAILURE: Build failed with an exception.

* What went wrong:
Execution failed for task ':app:preDebugBuild'.
> Android dependency 'com.facebook.react:react-native' has different version for the compile (0.58.3) and runtime (0.20.1) classpath. You should manually set the same version via DependencyResolution

Note: I had to change minSDK version from 16 to 19 to match with react-native-razorpay if that matters.

@sillysachin
Copy link

sillysachin commented Feb 27, 2019

The automatic steps did not work. The manual steps need a bit more of documentation to be clear how to follow.
https://medium.com/@sachin.r.r/using-razorpay-in-react-native-sample-3dea020de6a5

@devrohityadav
Copy link

Hey @devautor! Did you get it working?

@devautor
Copy link
Author

Hi @devrohityadav I couldn't then.

@sillysachin
Copy link

It is functional if you follow manual steps as i have pointed out https://medium.com/@sachin.r.r/using-razorpay-in-react-native-sample-3dea020de6a5

@AbhishekRn96
Copy link

AbhishekRn96 commented Mar 24, 2019

@sillysachin and every one it is working now as expected, just i had change the minSdkVersion in my top most build.gradle from 16 to 19, and it works perfectly for android. Thank you.

@satheeshkumar608
Copy link

Razorpay error Fix.docx

@sathishkrishnan20
Copy link

Could not help any of the above

@Nautiyalsachin
Copy link
Contributor

If you guys are still facing the issue, then please update your current package to the latest one i.e. 2.1.32.

Closing this issue due to the time elapsed. Please feel free to either re-open the issue or create a
new issue if you have any additional queries.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

7 participants