美文网首页
【flutter填坑】Using insecure protoc

【flutter填坑】Using insecure protoc

作者: 咸鱼本鱼丶 | 来源:发表于2022-03-01 09:31 被阅读0次

在升级Android12过程中,当升级了classpath 'com.android.tools.build:gradle:7.0.3'之后,sync gradle时出现如下错误日志

A problem occurred configuring project ':sharesdk_plugin'.
Could not resolve all dependencies for configuration ':sharesdk_plugin:classpath'.

Using insecure protocols with repositories, without explicit opt-in, 
is unsupported. Switch Maven repository 'maven(http://mvn.mob.com/android)' 
to redirect to a secure protocol (like HTTPS) or allow insecure protocols. 
See https://docs.gradle.org/7.0.2/dsl/org.gradle.api.artifacts.repositories.UrlArtifactRepository.html
#org.gradle.api.artifacts.repositories.UrlArtifactRepository:allowInsecureProtocol for more details. 

解决方法:
找到错误日志中提示的,maven(xxxx),然后增加配置allowInsecureProtocol

maven {
            url "http://mvn.mob.com/android"
            allowInsecureProtocol = true
        }

相关文章

网友评论

      本文标题:【flutter填坑】Using insecure protoc

      本文链接:https://www.haomeiwen.com/subject/qussrrtx.html