-
Notifications
You must be signed in to change notification settings - Fork 441
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
Missing Gradle project configuration file: .settings/org.eclipse.buildship.core.prefs #2528
Missing Gradle project configuration file: .settings/org.eclipse.buildship.core.prefs #2528
Comments
Help! It's been bothering me two days. @fbricon @Eskibear @gbraad @LightGuard @otaviof |
Please, do not just at-reply users to get attention. I have no idea what this is about. Especially as you just filed the issue and expect people to jump to your help. We also have a job and a life. |
Oh, sorry, It's github's Recommended. My fault. Have a good day. |
Recommended? This must be very wrong as it also includes people who aren't members of the organization. |
Really can't help. Using the com.sun.* packages have never been recommended. They're internal classes subject to change anytime. |
Apologize again. Happy weekend! 😄 |
Thx! okay, I got it. An open-source project that I study recently dependency the com.sun.* packages, I will remind the project side. |
@ai-chen2050 I can reproduce this. IIUC The problems "xxx is not API" will not stop you from debugging, but you just encountered another error about
|
I can also reproduce it via:
|
Thanks for the workaround @CsCherrYY, I had the same issue on GitHub Codespaces and your workaround worked perfectly. |
@ai-chen2050 I fixed "xxx is not API" errors in a gradle project like this:
plugins {
eclipse
// other plugins ...
}
eclipse {
classpath {
file {
whenMerged {
val classpath = this as org.gradle.plugins.ide.eclipse.model.Classpath
val jre = classpath.entries.find {
when (it) {
is org.gradle.plugins.ide.eclipse.model.Container -> it.path.contains("org.eclipse.jdt.launching.JRE_CONTAINER")
else -> false
}
} as org.gradle.plugins.ide.eclipse.model.Container
jre.accessRules.add(org.gradle.plugins.ide.eclipse.model.AccessRule("accessible", "com/sun/net/**"))
}
}
}
} |
[provide a description of the issue]
Environment
env:
Steps To Reproduce
1、use Oracle JDK 1.8 to run the program, and use OpenJDK 17 to jdt, as the java server.
2、compile https://github.com/tronprotocol/java-tron
[Please attach a sample project reproducing the error]
Please attach logs
Current Result
Error, Access restriction: The type 'OperatingSystemMXBean' is not API . Can't debug
Expected Result
No error
Additional Informations
java compile server some info as follow:
!ENTRY org.eclipse.jdt.ls.core 4 0 2022-06-24 00:40:59.039
!MESSAGE Error occured while building workspace. Details:
message: Access restriction: The method 'OperatingSystemMXBean.getProcessCpuLoad()' is not API (restriction on required library '/Library/Java/JavaVirtualMachines/jdk1.8.0_202.jdk/Contents/Home/jre/lib/rt.jar'); code: 16777523; resource: /Users/blake.chen/work/code/opensource/java-tron/common/src/main/java/org/tron/common/prometheus/OperatingSystemExports.java; line: 70
message: Access restriction: The method 'OperatingSystemMXBean.getSystemCpuLoad()' is not API (restriction on required library '/Library/Java/JavaVirtualMachines/jdk1.8.0_202.jdk/Contents/Home/jre/lib/rt.jar'); code: 16777523; resource: /Users/blake.chen/work/code/opensource/java-tron/common/src/main/java/org/tron/common/prometheus/OperatingSystemExports.java; line: 78
message: Access restriction: The method 'OperatingSystemMXBean.getTotalPhysicalMemorySize()' is not API (restriction on required library '/Library/Java/JavaVirtualMachines/jdk1.8.0_202.jdk/Contents/Home/jre/lib/rt.jar'); code: 16777523; resource: /Users/blake.chen/work/code/opensource/java-tron/common/src/main/java/org/tron/common/prometheus/OperatingSystemExports.java; line: 94
message: Access restriction: The method 'OperatingSystemMXBean.getFreePhysicalMemorySize()' is not API (restriction on required library '/Library/Java/JavaVirtualMachines/jdk1.8.0_202.jdk/Contents/Home/jre/lib/rt.jar'); code: 16777523; resource: /Users/blake.chen/work/code/opensource/java-tron/common/src/main/java/org/tron/common/prometheus/OperatingSystemExports.java; line: 102
message: Access restriction: The method 'OperatingSystemMXBean.getTotalSwapSpaceSize()' is not API (restriction on required library '/Library/Java/JavaVirtualMachines/jdk1.8.0_202.jdk/Contents/Home/jre/lib/rt.jar'); code: 16777523; resource: /Users/blake.chen/work/code/opensource/java-tron/common/src/main/java/org/tron/common/prometheus/OperatingSystemExports.java; line: 109
message: Access restriction: The method 'OperatingSystemMXBean.getFreeSwapSpaceSize()' is not API (restriction on required library '/Library/Java/JavaVirtualMachines/jdk1.8.0_202.jdk/Contents/Home/jre/lib/rt.jar'); code: 16777523; resource: /Users/blake.chen/work/code/opensource/java-tron/common/src/main/java/org/tron/common/prometheus/OperatingSystemExports.java; line: 116
message: Access restriction: The type 'OperatingSystemMXBean' is not API (restriction on required library '/Library/Java/JavaVirtualMachines/jdk1.8.0_202.jdk/Contents/Home/jre/lib/rt.jar'); code: 16777523; resource: /Users/blake.chen/work/code/opensource/java-tron/common/src/main/java/org/tron/common/prometheus/OperatingSystemExports.java; line: 5
message: Access restriction: The type 'OperatingSystemMXBean' is not API (restriction on required library '/Library/Java/JavaVirtualMachines/jdk1.8.0_202.jdk/Contents/Home/jre/lib/rt.jar'); code: 16777523; resource: /Users/blake.chen/work/code/opensource/java-tron/common/src/main/java/org/tron/common/prometheus/OperatingSystemExports.java; line: 44
message: Access restriction: The type 'OperatingSystemMXBean' is not API (restriction on required library '/Library/Java/JavaVirtualMachines/jdk1.8.0_202.jdk/Contents/Home/jre/lib/rt.jar'); code: 16777523; resource: /Users/blake.chen/work/code/opensource/java-tron/common/src/main/java/org/tron/common/prometheus/OperatingSystemExports.java; line: 47
message: Access restriction: The type 'OperatingSystemMXBean' is not API (restriction on required library '/Library/Java/JavaVirtualMachines/jdk1.8.0_202.jdk/Contents/Home/jre/lib/rt.jar'); code: 16777523; resource: /Users/blake.chen/work/code/opensource/java-tron/common/src/main/java/org/tron/common/prometheus/OperatingSystemExports.java; line: 51
message: Access restriction: The type 'OperatingSystemMXBean' is not API (restriction on required library '/Library/Java/JavaVirtualMachines/jdk1.8.0_202.jdk/Contents/Home/jre/lib/rt.jar'); code: 16777523; resource: /Users/blake.chen/work/code/opensource/java-tron/framework/src/main/java/org/tron/core/services/NodeInfoService.java; line: 3
message: Access restriction: The type 'OperatingSystemMXBean' is not API (restriction on required library '/Library/Java/JavaVirtualMachines/jdk1.8.0_202.jdk/Contents/Home/jre/lib/rt.jar'); code: 16777523; resource: /Users/blake.chen/work/code/opensource/java-tron/framework/src/main/java/org/tron/core/services/NodeInfoService.java; line: 41
message: Access restriction: The type 'OperatingSystemMXBean' is not API (restriction on required library '/Library/Java/JavaVirtualMachines/jdk1.8.0_202.jdk/Contents/Home/jre/lib/rt.jar'); code: 16777523; resource: /Users/blake.chen/work/code/opensource/java-tron/framework/src/main/java/org/tron/core/services/NodeInfoService.java; line: 41
message: Access restriction: The method 'OperatingSystemMXBean.getTotalPhysicalMemorySize()' is not API (restriction on required library '/Library/Java/JavaVirtualMachines/jdk1.8.0_202.jdk/Contents/Home/jre/lib/rt.jar'); code: 16777523; resource: /Users/blake.chen/work/code/opensource/java-tron/framework/src/main/java/org/tron/core/services/NodeInfoService.java; line: 75
message: Access restriction: The method 'OperatingSystemMXBean.getFreePhysicalMemorySize()' is not API (restriction on required library '/Library/Java/JavaVirtualMachines/jdk1.8.0_202.jdk/Contents/Home/jre/lib/rt.jar'); code: 16777523; resource: /Users/blake.chen/work/code/opensource/java-tron/framework/src/main/java/org/tron/core/services/NodeInfoService.java; line: 76
message: Access restriction: The method 'OperatingSystemMXBean.getSystemCpuLoad()' is not API (restriction on required library '/Library/Java/JavaVirtualMachines/jdk1.8.0_202.jdk/Contents/Home/jre/lib/rt.jar'); code: 16777523; resource: /Users/blake.chen/work/code/opensource/java-tron/framework/src/main/java/org/tron/core/services/NodeInfoService.java; line: 77
message: Access restriction: The method 'OperatingSystemMXBean.getProcessCpuLoad()' is not API (restriction on required library '/Library/Java/JavaVirtualMachines/jdk1.8.0_202.jdk/Contents/Home/jre/lib/rt.jar'); code: 16777523; resource: /Users/blake.chen/work/code/opensource/java-tron/framework/src/main/java/org/tron/core/services/NodeInfoService.java; line: 84
!ENTRY org.eclipse.jdt.ls.core 1 0 2022-06-24 00:41:01.712
!MESSAGE >> workspace/executeCommand vscode.java.resolveBuildFiles
The text was updated successfully, but these errors were encountered: