-
Notifications
You must be signed in to change notification settings - Fork 49
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
2023-09: Error while evaluating 'Array' logical structure for type java.util.Collection with the value 'return toArray();' #309
Comments
Session data:
|
Stack trace for Map:
|
Is this the right place to log the issue? |
Yes, it is. Please beso kindand attach small self containing example demonstrating the issue. |
Thank you. I've downgraded my eclipse yesterday, so i cannot provide an SCCE. Updated the description and how to reproduce. |
This reminds me on https://bugs.eclipse.org/bugs/show_bug.cgi?id=543604 , but that was fixed long time ago.
So if you want a fix for your issue, please provide exact steps to reproduce. |
Interesting, thank you for looking at this! |
Not for me, I have no access to any Mac machine. |
Don't see the issue with a clean install and a blank project. |
Behaviour on Mac: |
This issue cannot be reproduced when opening (with 2023-09) a clean workspace created with 2023-06. This is still a blocker for migration to 2023-09. Due to corporate restrictions, I cannot attach a copy of the workspace. |
I guess you can try to regenerate Java index under Preferences / Java. May be some types aren't properly resolved because of broken / not properly updated index? |
let me try that, but doesn't 'clean all projects' should take care of everything? |
No, index is independent from "clean". There are also such things like shared JDK / library symbols etc |
[rebuild index] did not help. |
No. Please note, you need to wait till index is rebuilt before trying. |
waited, even reloaded eclipse. I respectfully disagree: this is a regression, and a serious one. Pretty much every version since early 2000's could open and work with a workspace created by earlier versions (some even upgraded multiple times) with no issues, at least on my memory. I know it's a complex system, we are also dealing with ever increasing entropy in the Universe, but still - it's a blocker. What can I do to escalate? |
Well, if your organization is member of Eclipse IDE working group, you could ask your representative in that group to raise the priority of this issue on the next IDE WG meeting. Or you can ask your organization to hire some developer to debug & fix this issue. |
Unfortunately, my organization is not a member of Eclipse IDE working group. |
How to Become a Member: |
Same here with 2023-12. I get this if the application is started as modular only. That is if the application is modular itself or inside a workspace dependency if it is modular. |
not an option for my org, unfortunately. |
Thank you, you might be on something! |
@iloveeclipse |
I don't see exact steps to reproduce yet, sorry. If someone can provide something that I (or anyone else) would be able to reproduce, I would remove "needinfo". |
okay, here are the steps:
observe the error:
|
here is the complete test case: |
tried with eclipse-SDK-4.32M1-macosx-cocoa-aarch64.dmg same issue. I think, as @alerosmile has identified, the issue might be caused by a modular project (notice module-info.java in the zip I've sent earlier). |
Thanks, I can't promise but I will try to debug this this week. |
many thanks indeed! |
@andy-goryachev-oracle: Can you please confirm that this issue doesn't exist with Eclipse 2023-06? |
Yes, it works with built-in JDK17 and JDK21, using Eclipse 4.28.0.20230608-1200 downloaded from |
Changing this line to But as stated in this commit, this option seems to cause side effects I don't have knowledge of. |
OK, finally got time to test the reproducer. What was surprising for me: if testing in a Java perspective (with Variables view not activated), the hover over variables shows proper (but not "logical") content without errors. |
Yes, but the hover should be able to understand that preference, if it is set, without Variables view being active. Looking on the code in debugger I see that the two options used differently (well, they are different :-)). @stephan-herrmann : your brain is needed, as it is all about #260 and May I ask you to look into this issue? Example self contained project is in https://github.com/eclipse-jdt/eclipse.jdt.debug/files/14909705/ModularTest.zip |
ack |
Any chance to debug this in a JUnit test case? I briefly looked if I could create that test case, but after finding |
Initial compile error: So, contrary to what we discussed in eclipse-jdt/eclipse.jdt.core#445 the requirement by JDT/Debug is not just about allowing an unnamed/named module conflict, but also a conflict between two named modules should be ignored, right? The former would be covered by Is it a hard requirement in JDT/Debug to place the synthetic type I would indeed prefer a solution that could be made legal wrt JPMS. If that fails, going back to and fixing |
I didn't find an easy solution down this path.
|
OPTION_IgnoreUnnamedModuleForSplitPackage" This reverts commit f52ee57 as it caused regression. See eclipse-jdt#260 See also eclipse-jdt/eclipse.jdt.core#2340 Fixes eclipse-jdt#309
OPTION_IgnoreUnnamedModuleForSplitPackage" This reverts commit f52ee57 as it caused regression. See #260 See also eclipse-jdt/eclipse.jdt.core#2340 Fixes #309
@stephan-herrmann : once again, many thanks! Tomorrow I-build on https://download.eclipse.org/eclipse/downloads/ should have the fix for the ticket. |
You're welcome 😄 |
Verified, works fine with I20240414-1800 |
To reproduce:
I can see it on macOS with 2023-09.
Is this a resurrection of https://bugs.eclipse.org/bugs/show_bug.cgi?id=559505 ?
This is bad enough, I am forced to downgrade.
Error log:
The text was updated successfully, but these errors were encountered: