标签:15.0 jetified errors intellij Fix jar dependency org annotations
问题描述:
在集成百度地图时jar包、so库已同步到本地 在编译项目的时候报以下错误:
1 Duplicate class org.intellij.lang.annotations.Flow found in modules jetified-annotations-15.0.jar (org.jetbrains:annotations:15.0) and jetified-intellij_annotations.jar (intellij_annotations.jar) 2 Duplicate class org.intellij.lang.annotations.Identifier found in modules jetified-annotations-15.0.jar (org.jetbrains:annotations:15.0) and jetified-intellij_annotations.jar (intellij_annotations.jar) 3 Duplicate class org.intellij.lang.annotations.JdkConstants found in modules jetified-annotations-15.0.jar (org.jetbrains:annotations:15.0) and jetified-intellij_annotations.jar (intellij_annotations.jar) 4 Duplicate class org.intellij.lang.annotations.JdkConstants$AdjustableOrientation found in modules jetified-annotations-15.0.jar (org.jetbrains:annotations:15.0) and jetified-intellij_annotations.jar (intellij_annotations.jar) 5 Duplicate class org.intellij.lang.annotations.JdkConstants$BoxLayoutAxis found in modules jetified-annotations-15.0.jar (org.jetbrains:annotations:15.0) and jetified-intellij_annotations.jar (intellij_annotations.jar) 6 Duplicate class org.intellij.lang.annotations.JdkConstants$CalendarMonth found in modules jetified-annotations-15.0.jar (org.jetbrains:annotations:15.0) and jetified-intellij_annotations.jar (intellij_annotations.jar) 7 Duplicate class org.intellij.lang.annotations.JdkConstants$CursorType found in modules jetified-annotations-15.0.jar (org.jetbrains:annotations:15.0) and jetified-intellij_annotations.jar (intellij_annotations.jar) 8 Duplicate class org.intellij.lang.annotations.JdkConstants$FlowLayoutAlignment found in modules jetified-annotations-15.0.jar (org.jetbrains:annotations:15.0) and jetified-intellij_annotations.jar (intellij_annotations.jar) 9 Duplicate class org.intellij.lang.annotations.JdkConstants$FontStyle found in modules jetified-annotations-15.0.jar (org.jetbrains:annotations:15.0) and jetified-intellij_annotations.jar (intellij_annotations.jar) 10 Duplicate class org.intellij.lang.annotations.JdkConstants$HorizontalAlignment found in modules jetified-annotations-15.0.jar (org.jetbrains:annotations:15.0) and jetified-intellij_annotations.jar (intellij_annotations.jar) 11 Duplicate class org.intellij.lang.annotations.JdkConstants$InputEventMask found in modules jetified-annotations-15.0.jar (org.jetbrains:annotations:15.0) and jetified-intellij_annotations.jar (intellij_annotations.jar) 12 Duplicate class org.intellij.lang.annotations.JdkConstants$ListSelectionMode found in modules jetified-annotations-15.0.jar (org.jetbrains:annotations:15.0) and jetified-intellij_annotations.jar (intellij_annotations.jar) 13 Duplicate class org.intellij.lang.annotations.JdkConstants$PatternFlags found in modules jetified-annotations-15.0.jar (org.jetbrains:annotations:15.0) and jetified-intellij_annotations.jar (intellij_annotations.jar) 14 Duplicate class org.intellij.lang.annotations.JdkConstants$TabLayoutPolicy found in modules jetified-annotations-15.0.jar (org.jetbrains:annotations:15.0) and jetified-intellij_annotations.jar (intellij_annotations.jar) 15 Duplicate class org.intellij.lang.annotations.JdkConstants$TabPlacement found in modules jetified-annotations-15.0.jar (org.jetbrains:annotations:15.0) and jetified-intellij_annotations.jar (intellij_annotations.jar) 16 Duplicate class org.intellij.lang.annotations.JdkConstants$TitledBorderJustification found in modules jetified-annotations-15.0.jar (org.jetbrains:annotations:15.0) and jetified-intellij_annotations.jar (intellij_annotations.jar) 17 Duplicate class org.intellij.lang.annotations.JdkConstants$TitledBorderTitlePosition found in modules jetified-annotations-15.0.jar (org.jetbrains:annotations:15.0) and jetified-intellij_annotations.jar (intellij_annotations.jar) 18 Duplicate class org.intellij.lang.annotations.JdkConstants$TreeSelectionMode found in modules jetified-annotations-15.0.jar (org.jetbrains:annotations:15.0) and jetified-intellij_annotations.jar (intellij_annotations.jar) 19 Duplicate class org.intellij.lang.annotations.Language found in modules jetified-annotations-15.0.jar (org.jetbrains:annotations:15.0) and jetified-intellij_annotations.jar (intellij_annotations.jar) 20 Duplicate class org.intellij.lang.annotations.MagicConstant found in modules jetified-annotations-15.0.jar (org.jetbrains:annotations:15.0) and jetified-intellij_annotations.jar (intellij_annotations.jar) 21 Duplicate class org.intellij.lang.annotations.Pattern found in modules jetified-annotations-15.0.jar (org.jetbrains:annotations:15.0) and jetified-intellij_annotations.jar (intellij_annotations.jar) 22 Duplicate class org.intellij.lang.annotations.PrintFormat found in modules jetified-annotations-15.0.jar (org.jetbrains:annotations:15.0) and jetified-intellij_annotations.jar (intellij_annotations.jar) 23 Duplicate class org.intellij.lang.annotations.PrintFormatPattern found in modules jetified-annotations-15.0.jar (org.jetbrains:annotations:15.0) and jetified-intellij_annotations.jar (intellij_annotations.jar) 24 Duplicate class org.intellij.lang.annotations.RegExp found in modules jetified-annotations-15.0.jar (org.jetbrains:annotations:15.0) and jetified-intellij_annotations.jar (intellij_annotations.jar) 25 Duplicate class org.intellij.lang.annotations.Subst found in modules jetified-annotations-15.0.jar (org.jetbrains:annotations:15.0) and jetified-intellij_annotations.jar (intellij_annotations.jar) 26 Duplicate class org.jetbrains.annotations.Contract found in modules jetified-annotations-15.0.jar (org.jetbrains:annotations:15.0) and jetified-intellij_annotations.jar (intellij_annotations.jar) 27 Duplicate class org.jetbrains.annotations.Nls found in modules jetified-annotations-15.0.jar (org.jetbrains:annotations:15.0) and jetified-intellij_annotations.jar (intellij_annotations.jar) 28 Duplicate class org.jetbrains.annotations.NonNls found in modules jetified-annotations-15.0.jar (org.jetbrains:annotations:15.0) and jetified-intellij_annotations.jar (intellij_annotations.jar) 29 Duplicate class org.jetbrains.annotations.NotNull found in modules jetified-annotations-15.0.jar (org.jetbrains:annotations:15.0) and jetified-intellij_annotations.jar (intellij_annotations.jar) 30 Duplicate class org.jetbrains.annotations.Nullable found in modules jetified-annotations-15.0.jar (org.jetbrains:annotations:15.0) and jetified-intellij_annotations.jar (intellij_annotations.jar) 31 Duplicate class org.jetbrains.annotations.PropertyKey found in modules jetified-annotations-15.0.jar (org.jetbrains:annotations:15.0) and jetified-intellij_annotations.jar (intellij_annotations.jar) 32 Duplicate class org.jetbrains.annotations.TestOnly found in modules jetified-annotations-15.0.jar (org.jetbrains:annotations:15.0) and jetified-intellij_annotations.jar (intellij_annotations.jar) 33 34 Go to the documentation to learn how to Fix dependency resolution errors.
原因分析:
当时在网上各种文档也有所参考并没有解决我的问题,就仔细看了一下到底是什么类重复还是jar包重复。
随后仔细看build.gradle和libs有没有一样的类。
最终发现build.gradle下
dependencies { implementation 'org.jetbrains:annotations:15.0' }
ibs文件下的
intellij_annotations.jar
可能是这两个导致冲突
解决方案:
随后就删除了intellij_annotations.jar包在进行编译就好了
写文档时也没在继续实现地图定位逻辑直接记录问题,遇到问题后会继续发帖子的。
如有大牛看到此文章有什么不妥之处还请联系博主,博主及时改进。
标签:15.0,jetified,errors,intellij,Fix,jar,dependency,org,annotations 来源: https://www.cnblogs.com/why-info/p/14713364.html
本站声明: 1. iCode9 技术分享网(下文简称本站)提供的所有内容,仅供技术学习、探讨和分享; 2. 关于本站的所有留言、评论、转载及引用,纯属内容发起人的个人观点,与本站观点和立场无关; 3. 关于本站的所有言论和文字,纯属内容发起人的个人观点,与本站观点和立场无关; 4. 本站文章均是网友提供,不完全保证技术分享内容的完整性、准确性、时效性、风险性和版权归属;如您发现该文章侵犯了您的权益,可联系我们第一时间进行删除; 5. 本站为非盈利性的个人网站,所有内容不会用来进行牟利,也不会利用任何形式的广告来间接获益,纯粹是为了广大技术爱好者提供技术内容和技术思想的分享性交流网站。