Skip to content
This repository was archived by the owner on Jan 22, 2023. It is now read-only.
This repository was archived by the owner on Jan 22, 2023. It is now read-only.

Could not find .. :unspecified, when trying to inject a library module #227

@gabriel-rajadurai

Description

@gabriel-rajadurai

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.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions