1,问题

Build fails with an error:
Execution failed for task ':react-native-google-analytics-bridge:compileDebugJavaWithJavac'. package com.google.android.gms.tagmanager does not exist
import com.google.android.gms.tagmanager.TagManager;

RN android 突然报错,浏览查阅一大堆无果,隔了两天,又查了一下,找到一个解决方案 。

这个问题,是由于google play services 更新,并且自己代码又用‘+’指定的 版本号导致的。更新之后类不在原来的地方了,所以报缺失包的错。

2,解决

在 android/build.gradle里添加下面,start 和end 之间的代码,完美的解决了这个问题。

allprojects {
repositories {
//start here
configurations.all {
resolutionStrategy.eachDependency { DependencyResolveDetails details ->
def requested = details.requested
if (requested.group == 'com.google.android.gms') {
details.useVersion '12.0.1'
}
if (requested.group == 'com.google.firebase') {
details.useVersion '12.0.1'
}
}
}
//end
jcenter()
maven {
url "https://maven.google.com"
}
}
}

Build fails with an error: Execution failed for task ':react-native-google-analytics-bridge:compileDebugJavaWithJavac'.的更多相关文章

  1. Error:Execution failed for task ':app:transformClassesWithDexForDebug'. > com.android.build.api.transform.TransformException: com.android.ide.common.process.ProcessException: java.util.concurrent.Exec

    Error:Execution failed for task ':app:transformClassesWithDexForDebug'.> com.android.build.api.tr ...

  2. Error:Execution failed for task ':app:clean'. > Unable to delete directory: ***/app/build/generated/***

    第一次从svn拉下来的工程,在clean的时候会出现 Error:Execution failed for task ':app:clean'. > Unable to delete direc ...

  3. Error:Execution failed for task ':app:transformClassesWithDexForDebug'.

    使用android studio 时,编译成功但用build apk时却报错 环境: android studio 1.5, jdk1.7 错误:Error:Execution failed for ...

  4. Android Studio 运行出现 Error:Execution failed for task ':app:transformResourcesWithMergeJavaResForDebug'.

    转载请标明出处: http://www.cnblogs.com/why168888/p/5978381.html 本文出自:[Edwin博客园] 我引用compile 'com.squareup.re ...

  5. Error:Execution failed for task ':app:transformClassesWithDexForDebug'解决记录

    转载请标明出处: http://blog.csdn.net/lxk_1993/article/details/50511172 本文出自:[lxk_1993的博客]:   3个错误non-zero e ...

  6. 异常问题解决Error:Execution failed for task ':app:processDebugManifest'

    Error:Execution failed for task ':app:processDebugManifest' www.MyException.Cn  网友分享于:2015-12-28  浏览 ...

  7. BUG Error:Execution failed for task ':app:dexDebug'.

    Error:Execution failed for task ':app:dexDebug'. > com.android.ide.common.process.ProcessExceptio ...

  8. Error:Execution failed for task ':app:dexDebug'. > com.android.ide.common.process.ProcessException

    异常Log: Error:Execution failed for task ‘:app:dexDebug’. > com.android.ide.common.process.ProcessE ...

  9. tabpagerindictor:mergeReleaseResources FAILED Error:Execution failed for task ':tabpagerindictor:mergeReleaseResources'. > D:\android\adt-bundle-windows-x86_64-20140702\android-open-project-demo-mast

    解决:将项目移动到路径少的目录再运行即可 异常日志: D:\android\adt-bundle-windows-x86_64-20140702\android-open-project-demo-m ...

随机推荐

  1. ExceptionLess的MVC调用

    引用 <package id="Exceptionless" version="4.2.1989" targetFramework="net46 ...

  2. Socket.Io+HttpWebRequest 请求Api

    Socket 接收代码 <html> <head> <title>Socket Client Demo</title> <script src=& ...

  3. 2018软工实践作业八之UML设计

    1. 团队信息 队名:小白吃队 成员: 后敬甲 031602409 卢泽明 031602328 蔡文斌 031602301 葛亮 031602617 刘浩 031602423 黄泽 031602317 ...

  4. Dapper Helper

    using System; using System.Collections.Generic; using System.Configuration; using System.Data; using ...

  5. Zabbix监控Nginx性能状态

    Nginx在生产环境中的应用越来越广泛,所以需要对nginx的性能状态做一些监控,从而发现故障隐患,Ngnx的监控指标可分为:基本活动指标,错误指标,性能指标 监控Nginx思路: 1)首先,要想监控 ...

  6. SSH框架学习------struts2前后台传值(二)

    struts2的Action类一般都会继承(extends)ActionSupport类(Action类,即实现action的类)1.前传后:jsp里<input type="text ...

  7. 使用IntelliJ IDEA和Eclipse导入Github项目

    使用IntelliJ IDEA导入Github项目 菜单栏File->Settings->分别配置好Github和Git的相关信息,配置完之后点击旁边的Test按键可以查看是否配置成功 配 ...

  8. 想造轮子的时候,ctrl+f一下

    Chardet,字符编码探测器,可以自动检测文本.网页.xml的编码. colorama,主要用来给文本添加各种颜色,并且非常简单易用. Prettytable,主要用于在终端或浏览器端构建格式化的输 ...

  9. [OC] @property时,copy、strong、weak、assign的区别

    @property(copy,nonatomic)NSMutableString*copyStr; @property(strong,nonatomic)NSMutableString*strongS ...

  10. 英语口语练习系列-C30-生日-年历的周日和月份-如果白昼落进

    词汇-生日-birthday 生日庆祝 birthday celebration birth noun UK /bɜːθ/ US /bɝːθ/ the time when a baby or youn ...