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

Manifest merger failed after SDK Update 26.0.0 #4677

Closed
oncul opened this issue Aug 9, 2017 · 6 comments
Closed

Manifest merger failed after SDK Update 26.0.0 #4677

oncul opened this issue Aug 9, 2017 · 6 comments

Comments

@oncul
Copy link

oncul commented Aug 9, 2017

Dear friend, we, the rest of the NativeScript community really
appreciate your feedback! While we are doing all we can to take care of every
issue, sometimes we get overwhelmed. Because of that, we will consider issues
that are not constructive or problems that cannot be reproduced "dead".
Additionally, we will treat feature requests or bug reports with unanswered
questions regarding the behavior/reproduction for more than 20 days "dead". All
"dead" issues will get closed.

Please, provide the details below:

I updated SDK from android sdk manager. After sdk update tns run android shows error.

Execution failed for task ':processF0F1F2F3F4F5F6F7F8F9F10F11F12DebugManifest'.
> Manifest merger failed : Attribute meta-data#android.support.VERSION@value value=(26.0.0-alpha1) from [com.android.support:design:26.0.0-alpha1] AndroidManifest.xml:27:9-38
        is also present at [com.android.support:customtabs:25.3.1] AndroidManifest.xml:24:9-31 value=(25.3.1).
        Suggestion: add 'tools:replace="android:value"' to <meta-data> element at AndroidManifest.xml:25:5-27:41 to override.

Did you verify this is a real problem by searching Stack Overflow and the other open issues in this repo?

Tell us about the problem

Please, ensure your title is less than 63 characters long and starts with a capital
letter.

Which platform(s) does your issue occur on?

iOS/Android/Both

Please provide the following version numbers that your issue occurs with:

  • CLI: (run tns --version to fetch it)
  • Cross-platform modules: (check the 'version' attribute in the
    node_modules/tns-core-modules/package.json file in your project)
  • Runtime(s): (look for the "tns-android" and "tns-ios" properties in the
    package.json file of your project)
  • Plugin(s): (look for the version number in the package.json file of your
    project)
│ Component        │ Current version │ Latest version │ Information   │
│ nativescript     │ 3.1.3           │ 3.1.3          │ Up to date    │
│ tns-core-modules │ 3.1.1           │ 3.1.1          │ Up to date    │
│ tns-android      │ 3.1.1           │ 3.1.1          │ Up to date    │
│ tns-ios          │                 │ 3.1.0          │ Not installed

Please tell us how to recreate the issue in as much detail as possible.

Is there code involved? If so, please share the minimal amount of code needed to recreate the problem.

@DickSmith
Copy link
Contributor

DickSmith commented Aug 9, 2017

dependencies {
    configurations.all {
        resolutionStrategy.eachDependency { DependencyResolveDetails details ->
            def requested = details.requested
            if (requested.group == 'com.android.support') {
                details.useVersion '26.0.+'
            }
        }
    }
}

Add that to your app/App_Resources/Android/app.gradle or merge it with whatever you have in dependencies {...} already and you should be good.

@tsonevn
Copy link
Contributor

tsonevn commented Aug 10, 2017

Hi @cagatayoncul,
Were you able to solve your case, while following the suggestion provided by @DickSmith ?

@Burgov
Copy link

Burgov commented Mar 19, 2018

@DickSmith 's suggestion resolved the problem for me. Thanks

@evertonrobertoauler
Copy link

Thanks @DickSmith, but I had one issue with com.android.support:multidex using your suggestion, I needed to add one exception on your script:

  configurations.all {
    resolutionStrategy.eachDependency { DependencyResolveDetails details ->
      def requested = details.requested
      if (requested.group == 'com.android.support') {
         if (!requested.name.startsWith("multidex")) {
          details.useVersion '26.0.+'
         }
      }
    }
  }

@adityajaiz
Copy link

Thanks @DickSmith, but I had one issue with com.android.support:multidex using your suggestion, I needed to add one exception on your script:

  configurations.all {
    resolutionStrategy.eachDependency { DependencyResolveDetails details ->
      def requested = details.requested
      if (requested.group == 'com.android.support') {
         if (!requested.name.startsWith("multidex")) {
          details.useVersion '26.0.+'
         }
      }
    }
  }

Thank you! this helps, I was stuck for so long and this solution helped me-
configurations.all {
resolutionStrategy{
force 'com.android.support:support-v4:26.0.0'
}

    resolutionStrategy.eachDependency { DependencyResolveDetails details ->
  def requested = details.requested
  if (requested.group == 'com.android.support') {
     if (!requested.name.startsWith("multidex")) {
      details.useVersion '26.0.0'
     }
  }
}

}

@lock
Copy link

lock bot commented Nov 13, 2019

This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

@lock lock bot locked and limited conversation to collaborators Nov 13, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

7 participants