Suppress NPE in JDT LookupEnvironment
Maintainer thường phản hồi trong vòng 1 ngày
Đánh giá
- Độ khó
- 3/5
- Thời gian dự kiến
- 1-2 ngày
- Mức phù hợp với người mới
- 48/100
- Loại issue
- Lỗi
- Độ rõ ràng
- Khá rõ ràng
- Mức độ hoạt động
- Sôi nổi
- Công nghệ
- java
- Lĩnh vực
- testing-qa
Hướng nghiên cứu
Start with the failing workflow run and trace the test teardown around the reported LookupEnvironment stack trace. Read the test lifecycle code and the AfterEachCallback extension guidance in the issue; done means this expected NPE no longer fails the tests and teardown still runs through the intended callback.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
As seen in https://github.com/eclipse-windowbuilder/windowbuilder/runs/109588061970.
!MESSAGE Designer [1.26.0.202609291849.202609291858]: Cannot read the array length because "signature" is null
!STACK 0
java.lang.NullPointerException: Cannot read the array length because "signature" is null
at org.eclipse.jdt.internal.compiler.lookup.LookupEnvironment.getTypeFromConstantPoolName(LookupEnvironment.java:1918)
at org.eclipse.jdt.internal.compiler.lookup.LookupEnvironment.getTypeFromConstantPoolName(LookupEnvironment.java:1937)
at org.eclipse.jdt.internal.compiler.lookup.BinaryTypeBinding.cachePartsFrom(BinaryTypeBinding.java:463)
at org.eclipse.jdt.internal.compiler.lookup.LookupEnvironment.createBinaryTypeFrom(LookupEnvironment.java:1077)
at org.eclipse.jdt.internal.compiler.lookup.LookupEnvironment.createBinaryTypeFrom(LookupEnvironment.java:1058)
at org.eclipse.jdt.internal.compiler.Compiler.accept(Compiler.java:307)
at org.eclipse.jdt.internal.compiler.lookup.LookupEnvironment.askForType(LookupEnvironment.java:296)
at org.eclipse.jdt.internal.compiler.lookup.UnresolvedReferenceBinding.resolve(UnresolvedReferenceBinding.java:116)
at org.eclipse.jdt.internal.compiler.lookup.BinaryTypeBinding.resolveType(BinaryTypeBinding.java:251)
at org.eclipse.jdt.internal.compiler.lookup.PackageBinding.getTypeOrPackage(PackageBinding.java:252)
at org.eclipse.jdt.internal.compiler.lookup.Scope.getType(Scope.java:3341)
at org.eclipse.jdt.internal.compiler.ast.TypeDeclaration.resolve(TypeDeclaration.java:1374)
at org.eclipse.jdt.internal.compiler.ast.TypeDeclaration.resolve(TypeDeclaration.java:1646)
at org.eclipse.jdt.internal.compiler.ast.CompilationUnitDeclaration.resolve(CompilationUnitDeclaration.java:666)
at org.eclipse.jdt.core.dom.CompilationUnitResolver.resolve(CompilationUnitResolver.java:1326)
at org.eclipse.jdt.core.dom.CompilationUnitResolver.resolve(CompilationUnitResolver.java:791)
at org.eclipse.jdt.core.dom.ASTParser.internalCreateASTCached(ASTParser.java:1248)
at org.eclipse.jdt.core.dom.ASTParser.lambda$0(ASTParser.java:1126)
at org.eclipse.jdt.internal.core.JavaModelManager.cacheZipFiles(JavaModelManager.java:5765)
at org.eclipse.jdt.core.dom.ASTParser.internalCreateAST(ASTParser.java:1126)
at org.eclipse.jdt.core.dom.ASTParser.createAST(ASTParser.java:874)
at org.eclipse.wb.internal.core.utils.jdt.core.CodeUtils.parseCompilationUnit(CodeUtils.java:113)
at org.eclipse.wb.internal.core.utils.jdt.core.CodeUtils.parseCompilationUnit(CodeUtils.java:97)
at org.eclipse.wb.internal.core.utils.ast.AstEditor.<init>(AstEditor.java:118)
at org.eclipse.wb.internal.core.parser.JavaInfoParser.<init>(JavaInfoParser.java:207)
at org.eclipse.wb.internal.core.parser.JavaInfoParser.parse(JavaInfoParser.java:148)
at org.eclipse.wb.internal.core.editor.DesignPage.internal_refreshGEF(DesignPage.java:520)
at org.eclipse.wb.internal.core.editor.DesignPage$3.run(DesignPage.java:438)
at org.eclipse.jface.operation.ModalContext$ModalContextThread.run(ModalContext.java:124)
The failure happened when testing against the 2024-06 Eclipse and the LookupEnvironment class looks completely different now. Even if a similar problem still exists, it would not have a different stack trace. In any case, there is nothing we can really do here, so it should not cause the tests to fail.
As an additional note: Failing while tearing down the test case is likely not a very good idea, because it risks leaving stale resources behind. It should probably be moved to an AfterEachCallback extension.
- Ngôn ngữ chính
- Java
- Star
- 97
- Fork
- 34
- Merge trung bình
- 23 giờ 46 phút
- Pull request đã merge (30 ngày)
- 51
Chuẩn bị môi trường
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Issue khác của eclipse-windowbuilder/windowbuilder
-
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 86/100
eclipse-windowbuilder/windowbuilder#1602 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
WindowBuilder 1.26.0Đang mở
Độ khó 3/5 1-2 ngày Mức phù hợp với người mới 40/100
eclipse-windowbuilder/windowbuilder#1635 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
good first issue
Độ khó 3/5 1-2 ngày Mức phù hợp với người mới 65/100
eclipse-windowbuilder/windowbuilder#1632 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 3/5 1-2 ngày Mức phù hợp với người mới 70/100
eclipse-windowbuilder/windowbuilder#1627 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 3/5 1-2 ngày Mức phù hợp với người mới 78/100
eclipse-windowbuilder/windowbuilder#1608 ·
Maintainer thường phản hồi trong vòng 1 ngày
Tất cả issue của eclipse-windowbuilder/windowbuilder
Issue tương tự
-
[Bug] Logo style setting missing and `classic` style not applied across multiple platforms (v3.1.0)Đang mở
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 75/100
Stirling-Tools/Stirling-PDF#8382 · 1 reaction ·
Maintainer thường phản hồi trong vòng 2 ngày
-
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 70/100
Maintainer thường phản hồi trong vòng 4 ngày
-
enhancement untriaged
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 78/100
opensearch-project/sql#5842 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 85/100
openhab/openhab-addons#21882 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 78/100
YunaiV/ruoyi-vue-pro#1273 ·
Maintainer thường phản hồi trong vòng 3 ngày