Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

升级javassist到3.22.0-GA版本,过滤module-info.class,解决 java.io.IOException: invalid constant type: 19 at 5 #431

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

yflei88
Copy link

@yflei88 yflei88 commented Sep 28, 2020

背景:
gradle版本:6.5
gradle插件版本:3.6.3
在打开robust插件编译过程中出现一下错误

java.lang.RuntimeException: java.io.IOException: invalid constant type: 19 at 5
at javassist.CtClassType.getClassFile2(CtClassType.java:211)
at javassist.CtClassType.getModifiers(CtClassType.java:407)
at robust.gradle.plugin.asm.AsmInsertImpl.insertCode(AsmInsertImpl.java:54)
经过排查,出现的原因是javassist版本过低导致,因此此提交做了一下两项工作:
1、升级javassist,从3.20.0-GA升级到3.22.0-GA。
2、在类处理过程中,过滤掉3.22.0-GA版本产生的module-info.class,否则在编译的过程中会出现一下错误:
image

@yflei88 yflei88 changed the title 升级javassist到3.22.0-GA版本,过滤module-info.class。 升级javassist到3.22.0-GA版本,过滤module-info.class,解决java.lang.RuntimeException: java.io.IOException: invalid constant type: 19 at 5 Sep 28, 2020
@yflei88 yflei88 changed the title 升级javassist到3.22.0-GA版本,过滤module-info.class,解决java.lang.RuntimeException: java.io.IOException: invalid constant type: 19 at 5 升级javassist到3.22.0-GA版本,过滤module-info.class,解决 java.io.IOException: invalid constant type: 19 at 5 Sep 28, 2020
@YummyLau
Copy link

这个问题我也遇到了.官方不不打算处理下么?

@yflei88
Copy link
Author

yflei88 commented Jan 30, 2021

这个问题我也遇到了.官方不不打算处理下么?

按照我这个commit去修改一下源码就可以了

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants