Some problems were encountered while building the effective settings

来源:2-3 Mybatis接入SpringBoot项目

qq_慕婉清2369459

2021-02-22 10:42

在学龙虾三少的SpringBoot构建电商基础秒杀项目时,运行maven项目,出现报错

Some problems were encountered while building the effective settings

Expected root element 'settings' but found 'w:wordDocument' (position: START_TAG seen ... w:embeddedObjPresent="no" w:ocxPresent="no" xml:space="preserve">... @3:543) @ /Users/lixuzhao/.m2/settings.xml, line 3, column 543

经指点是setting配置文件出现错误

但是在网上换了很多个配置文件,仍然报错

Some problems were encountered while building the effective settings

Expected root element 'settings' but found 'w:wordDocument' (position: START_TAG seen ... w:embeddedObjPresent="no" w:ocxPresent="no" xml:space="preserve">... @3:1704) @ /Users/lixuzhao/.m2/settings.xml, line 3, column 1704

配置文件如下<?xml version="1.0" encoding="UTF-8"?>
<settings xmlns="http://maven.apache.org/SETTINGS/1.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/SETTINGS/1.0.0 http://maven.apache.org/xsd/settings-1.0.0.xsd">
<pluginGroups>
</pluginGroups>
<proxies>
</proxies>
<servers>
</servers>
<mirrors>
<!-- 这里使用的是阿里的远程maven镜像,目前国内大多数都使用它 -->
<mirror>
<id>alimaven</id>
<name>aliyun maven</name>
<url>http://maven.aliyun.com/nexus/content/groups/public/</url>
<mirrorOf>central</mirrorOf>
</mirror>
</mirrors>
<profiles>
<profile>
<id>jdk-1.8</id>
<activation>
<activeByDefault>true</activeByDefault>
<jdk>1.8</jdk>
</activation>
<properties>
<maven.compiler.source>1.8</maven.compiler.source>
<maven.compiler.target>1.8</maven.compiler.target>
<maven.compiler.compilerVersion>1.8</maven.compiler.compilerVersion>
</properties>
</profile>
</profiles>
</settings>
不晓得现在应该怎么调试


写回答 关注

1回答

  • 天地刍狗
    2021-05-16 20:38:27

    idea左上角设置里构建、maven里打开看看你加载的是哪个配置文件,是不是加载错了

    报错的意思是说找不到根节点<settings,只有w:wordDocument这玩意,这乍看像是Word文档你不会是用Word修改没保存吧,

    报错信息里叫你去c盘/Users/lixuzhao/.m2/settings.xml文件里,看看第三行的内容是不是搞错了

SpringBoot构建电商基础秒杀项目

应用SpringBoot快速搭建拥有用户、商品、交易及秒杀活动的电商秒杀应用。

49065 学习 · 954 问题

查看课程

相似问题