Metals 0.11.1 Queries & Observations #3535
Replies: 6 comments 18 replies
-
Thanks for another portion of feedback @vishalovercome. |
Beta Was this translation helpful? Give feedback.
-
I converted this into discussion, since this isn't exactly one issue. Let's try to open issue related to one particular problem that we can fix.
Could you explain a bit more about it? Is it the compialtion taking more time? Maybe it's more memory being used with Java files added and we could increase Xmx? |
Beta Was this translation helpful? Give feedback.
-
@Arthurm1 can you shed light on the next steps on Java support? In an another thread you had said that disabling Java support would not be easy. These are the current problems that need to be solved:
|
Beta Was this translation helpful? Give feedback.
-
@vishalovercome Thanks for all the feedback. In terms of new functionality - that's undecided. But I'm certainly looking at the various issues that have been raised.
This shouldn't happen - Bloop should happily compile any java code that SBT has compiled. The only thing I can think of is that incremental compilation has an issue with a certain set of changes. Does this happen after issuing a I'd like to know more about your project setup i.e. how many projects Metals lists and do you have scala code that depends on java source or vice versa or mixed. What version of Java are you targeting (seems like JDK 11 from your stacktraces?) Also - how were you using the RedHat Java plugin in combination with Metals before we added java functionality - was it with pure java projects - if not, how were you getting it to compile Scala?
Is this the same as you've written above
This is for Java files or Scala files? I can try and reproduce this but do need to know how you've setup your project files to work with the java plugin. Currently we respond to VScode's |
Beta Was this translation helpful? Give feedback.
-
Would you recommend a JDK other than AdoptOpenJDK? I've read that Zulu JDK results in much better IntelliJ performance but I've never seen any such recommendations in Metals/Bloop doc |
Beta Was this translation helpful? Give feedback.
-
@vishalovercome I've had a play with using SBT + Lombok + Java + Scala + Metals. Metals seems to handle compilation (in java + scala) and code completion (in scala) ok. A simple Java class... package foo;
import lombok.Data;
@Data
class Foo {
public String bar;
} gets compiled to... class Foo {
public String bar;
public String getBar() {
return this.bar;
}
public void setBar(String string) {
this.bar = string;
}
public boolean equals(Object object) {
if (object == this) {
return true;
}
if (!(object instanceof Foo)) {
return false;
}
Foo foo = (Foo)object;
if (!foo.canEqual(this)) {
return false;
}
String string = this.getBar();
String string2 = foo.getBar();
return !(string == null ? string2 != null : !string.equals(string2));
}
protected boolean canEqual(Object object) {
return object instanceof Foo;
}
public int hashCode() {
int n = 1;
String string = this.getBar();
n = n * 59 + (string == null ? 43 : string.hashCode());
return n;
}
public String toString() {
return "Foo(bar=" + this.getBar() + ")";
}
} and those extra methods can be used in Scala in the same project. This compiles fine... package foo
object BarGetter {
val aFoo = new foo.Foo()
aFoo.getBar()
} You can't navigate to My SBT project is very simple. I'm using Java 17, hence the additional javac options...
Could you see if a you could setup a small project that reproduces your issues. Maybe you have some specific build settings that are causing annotation processing issues within bloop. |
Beta Was this translation helpful? Give feedback.
-
ERROR ERROR StatusLogger Reconfiguration failed: No configuration found for '250b5e5b' at 'null' in 'null'
15431 -- main class information unavailable
java.lang.AssertionError: NoDenotation.owner
again #3532 with the new releaseBeta Was this translation helpful? Give feedback.
All reactions