maven项目依赖出现Failed to read artifact descriptor for xxx
问题描述
在写springcloud项目的时候,A项目依赖B项目提示出现:Failed to read artifact descriptor for com.wxzjar:0.0.1-SNAPSHOT,如下图所示:
解决办法
找到被依赖的B项目,将pom文件中的dependencyManagement
属性里面的dependencies
属性里面的dependency
的scope
属性值改为compile
,即
<dependencyManagement>
<dependencies>
<dependency>
<groupId>org.springframework.cloud</groupId>
<artifactId>spring-cloud-dependencies</artifactId>
<version>${spring-cloud.version}</version>
<type>pom</type>
<scope>compile</scope>
</dependency>
</dependencies>
</dependencyManagement>
如下图所示:
然后即可解决问题
还没有评论,来说两句吧...