-
Notifications
You must be signed in to change notification settings - Fork 41
Could not find .. :unspecified, when trying to inject a library module #227
Description
I took the sample project available in the repo, added another module utils. Then instead of injecting the lottie library, I injected this module instead.
inject project(':utils')
But this failed with,
Cannot choose between the following variants of project :utils: - debugRuntimeElements - releaseRuntimeElements
A stackoverflow answer suggested to keep configuration as default,
inject project(path: ':utils', configuration: 'default')
This worked, but when building the project, I get the following error.
`Execution failed for task ':lib:javaPreCompileDebug'.
Could not resolve all files for configuration ':lib:debugCompileClasspath'.
Could not find injector-android-example:utils:unspecified.
Searched in the following locations:
- https://dl.google.com/dl/android/maven2/injector-android-example/utils/unspecified/utils-unspecified.pom
- https://dl.google.com/dl/android/maven2/injector-android-example/utils/unspecified/utils-unspecified.jar
- https://repo.maven.apache.org/maven2/injector-android-example/utils/unspecified/utils-unspecified.pom
- https://repo.maven.apache.org/maven2/injector-android-example/utils/unspecified/utils-unspecified.jar
- https://jcenter.bintray.com/injector-android-example/utils/unspecified/utils-unspecified.pom
- https://jcenter.bintray.com/injector-android-example/utils/unspecified/utils-unspecified.jar
Required by:
project :lib
- Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.
==============================================================================
2: Task failed with an exception.
- What went wrong:
Execution failed for task ':lib:mergeDebugManifest'.
com.android.manifmerger.ManifestMerger2$MergeFailureException: java.io.FileNotFoundException: /Users/gabriel/Development/Injector/injector-android-example/lib/build/exploded-aar/injector-android-example/utils/unspecified/AndroidManifest.xml (No such file or directory)`
From the error logs, it seems to be trying to find the module in the maven repositories setup in the project gradle, instead of local project directory.