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

Detox build command is failing due to dagger files under build section of android app #2276

Closed
ganeshpadhayay opened this issue Aug 14, 2020 · 2 comments

Comments

@ganeshpadhayay
Copy link

ganeshpadhayay commented Aug 14, 2020

Describe the bug
The detox build command is failing due to dagger files under build section of android app

detox command: detox build -c android.emu.beta.debug

my detoxsrc file,

{
"testRunner": "jest",
"runnerConfig": "e2e/config.json",
"configurations": {
"android.emu.beta.debug": {
"binaryPath": "android/app/build/outputs/apk/beta/debug/app-beta-debug.apk",
"build": "cd android && ./gradlew assembleBetaDebug assembleBetaDebugAndroidTest -DtestBuildType=debug && cd ..",
"type": "android.emulator",
"device": {
"avdName": "Pixel_2_API_30"
}
},
"android.emu.beta.release": {
"binaryPath": "android/app/build/outputs/apk/beta/release/app-beta-release.apk",
"build": "cd android && ./gradlew assembleBetaRelease assembleBetaReleaseAndroidTest -DtestBuildType=release && cd ..",
"type": "android.emulator",
"device": {
"avdName": "Pixel_2_API_30"
}
}
}
}

Steps to reproduce:

  1. setup detox in a dagger android project
  2. try to build the project
  3. Execution failed for task ':app:compileLIVEDebugJavaWithJavac' due to the dagger generated files under build section

the same error is reproduced when I try to run the android app via terminal through this command "npx react-native run-android --variant BETADebug -- stacktrace" so I think the problem might be in android dagger part and not in detox part.

Screenshots:
Screenshot 2020-08-14 at 3 28 41 PM

Environment (please complete the following information):

  • Detox: 17.3.6
  • React Native: 0.63.0
  • Node: 14.4.0
  • Device: Android
  • OS: Mac
  • Test-runner (select one): jest-circus
@noomorph
Copy link
Collaborator

Exactly. Detox has no relation to the build process for your app.

@ganeshpadhayay
Copy link
Author

If anyone else is facing this-> Check what version of java is being used by your terminal it might be 14, change it back to 8 and it should work fine

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

No branches or pull requests

3 participants