React-native: stetho-okhttp depends on one or more Android Libraries but is a jar

Created on 4 Oct 2016  路  7Comments  路  Source: facebook/react-native

Issue Description

I'm trying to include react-native in an existing android project. In this project, I'm already using stetho, specifically:

debugCompile 'com.facebook.stetho:stetho:1.4.1'
debugCompile 'com.facebook.stetho:stetho-okhttp3:1.4.1'

When I try to build the project I get an error:

Module 'com.facebook.stetho:stetho-okhttp:1.2.0' depends on one or more Android Libraries but is a jar

If I remove stetho from "the old app" this error goes away

Additional Information

  • React Native version: 0.34.1
  • Platform(s) (iOS, Android, or both?): Android
  • Operating System (macOS, Linux, or Windows?): Linux
Locked

Most helpful comment

@JuiceCrawl et al - forgot to post, but for the sake of posterity we temporarily resolved as follows:

  compile ("com.facebook.react:react-native:0.41.2") {
    exclude group:'com.facebook.stetho', module:'stetho'
  }

not sure what side effects this has for RN debugging, but it was the only wait to get the build to pass

All 7 comments

+0.35.0

Did you ever figure this out? In general it seems like React Native does not necessarily support using different versions of the dependencies that React Native uses itself, which is annoying.

Was there a resolution? We can't get rid of our version of Stetho because we're using okhttp3 in our API client. Would be nice to get some contributor help on this

Having the same issue. Any updates?

@JuiceCrawl et al - forgot to post, but for the sake of posterity we temporarily resolved as follows:

  compile ("com.facebook.react:react-native:0.41.2") {
    exclude group:'com.facebook.stetho', module:'stetho'
  }

not sure what side effects this has for RN debugging, but it was the only wait to get the build to pass

Hi there! This issue is being closed because it has been inactive for a while. Maybe the issue has been fixed in a recent release, or perhaps it is not affecting a lot of people. Either way, we're automatically closing issues after a period of inactivity. Please do not take it personally!

If you think this issue should definitely remain open, please let us know. The following information is helpful when it comes to determining if the issue should be re-opened:

  • Does the issue still reproduce on the latest release candidate? Post a comment with the version you tested.
  • If so, is there any information missing from the bug report? Post a comment with all the information required by the issue template.
  • Is there a pull request that addresses this issue? Post a comment with the PR number so we can follow up.

If you would like to work on a patch to fix the issue, contributions are very welcome! Read through the contribution guide, and feel free to hop into #react-native if you need help planning your contribution.

Still having the same issue.
Module 'com.facebook.stetho:stetho-okhttp:1.2.0' depends on one or more Android Libraries but is a jar
Any one have the solution please ?

Was this page helpful?
0 / 5 - 0 ratings

Related issues

phongyewtong picture phongyewtong  路  3Comments

axelg12 picture axelg12  路  3Comments

despairblue picture despairblue  路  3Comments

oney picture oney  路  3Comments

grabbou picture grabbou  路  3Comments