[WARNING] Corrupted STDOUT by directly writing to native stream in forked JVM 1

在执行Maven install时遇到[WARNING] Corrupted STDOUT by directly writing to native stream in forked JVM1警告。问题源于Surefire插件版本过高,降低到2.18以下可避免崩溃,但不执行测试。为保持测试,通过IDEA配置跳过测试类解决问题。若需执行测试,考虑按建议调整Surefire插件版本。
摘要由CSDN通过智能技术生成

昨天打包项目的时候,进行maven install遇到了这个问题

[WARNING] Corrupted STDOUT by directly writing to native stream in forked JVM 1

查阅之后在starkoverFlow找到了相关的问题解答

作者说:

Dropping the surefire version to 2.18 stops the jvm from crashing but does not execute the tests. Any version of surefire above 2.18 including the latest crashes the build with the errors above.

I am clearly not the only one experiencing the issue as it is also shown here

Furthermore the issue is also known by the surefire development community as it is discussed here

That said, unlike most issues that tend to be resolved in more recent version of plugins, this issue appears to raise its ugly head again with the more recent versions of surefire and the jvm.

翻译过来就是说Maven的surefire插件版本如果超过2.18,那么就会报这个错误,建议你把该插件版本降到2.18及以下。

然后我查看了我项目中这个插件的版本,发现确实是超过了2.18
在这里插入图片描述
但是肯定是不能直接降插件版本的,因为除了插件问题,测试类也可能有问题,所以只要跳过测试类即可,如果你是idea开发环境,直接在配置里勾选跳过测试即可
在这里插入图片描述
至此问题解决,但是如果你需要测试类,你可能需要按照上面那个老哥说的降一下版本。

评论 4
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值