我为 Eclipse 安装安装了更新,但它再次无法启动。为了避免进行全新安装和恢复所有插件和自定义设置的乏味,我一直在尝试研究解决方案。最终我找到了一个 SO 答案,建议使用 -Console 和 -ConsoleLog 启动 Eclipse。所以现在我有一个近 500 行的日志文件。查了一下,问题的核心似乎是加载一些关键模块。
WARNING: Using incubator modules: jdk.incubator.vector
Dec 17, 2024 2:33:31 PM org.apache.aries.spifly.BaseActivator log
INFO: Registered provider org.slf4j.simple.SimpleServiceProvider of service org.slf4j.spi.SLF4JServiceProvider in bundle slf4j.simple
!SESSION 2024-12-17 14:33:23.006 -----------------------------------------------
eclipse.buildId=4.34.0.20241128-0756
java.version=21.0.3
java.vendor=Oracle Corporation
BootLoader constants: OS=win32, ARCH=x86_64, WS=win32, NL=en_AU
Framework arguments: -product org.eclipse.epp.package.cpp.product
Command-line arguments: -os win32 -ws win32 -arch x86_64 -product org.eclipse.epp.package.cpp.product -console -consoleLog
!ENTRY org.eclipse.cbi.targetplatform 4 0 2024-12-17 14:33:32.443
!MESSAGE FrameworkEvent ERROR
!STACK 0
org.osgi.framework.BundleException: Could not resolve module: org.eclipse.cbi.targetplatform [304]
Unresolved requirement: Require-Bundle: org.eclipse.xtext
-> Bundle-SymbolicName: org.eclipse.xtext; bundle-version="2.25.0.v20210301-0843"; singleton:="true"
org.eclipse.xtext [1858]
Unresolved requirement: Require-Bundle: org.eclipse.xtext.util; visibility:="reexport"
-> Bundle-SymbolicName: org.eclipse.xtext.util; bundle-version="2.25.0.v20210301-0843"
org.eclipse.xtext.util [1881]
Unresolved requirement: Require-Bundle: com.google.guava; bundle-version="[30.1.0,31.0.0)"; visibility:="reexport"
-> Bundle-SymbolicName: com.google.guava; bundle-version="30.1.0.v20221112-0806"
com.google.guava [49]
Unresolved requirement: Import-Package: com.google.errorprone.annotations; version="[3.0.0,4.0.0)"; resolution:="optional"
Unresolved requirement: Import-Package: com.google.errorprone.annotations.concurrent; version="[3.0.0,4.0.0)"; resolution:="optional"
Unresolved requirement: Import-Package: javax.crypto; version="[3.0.0,4.0.0)"; resolution:="optional"
Unresolved requirement: Import-Package: javax.crypto.spec; version="[3.0.0,4.0.0)"; resolution:="optional"
Unresolved requirement: Import-Package: org.checkerframework.checker.nullness.qual; version="[3.5.0,4.0.0)"; resolution:="optional"
Unresolved requirement: Import-Package: org.apache.log4j; version="1.2.15"
-> Export-Package: org.apache.log4j; bundle-symbolic-name="org.apache.log4j"; bundle-version="1.2.15.v201012070815"; version="1.2.15"
org.apache.log4j [248]
No resolution report for the bundle. Unresolved requirement: Require-Bundle: org.eclipse.xtend.lib
-> Bundle-SymbolicName: org.eclipse.xtend.lib; bundle-version="2.36.0.v20240825-0714"
org.eclipse.xtend.lib [1848]
Unresolved requirement: Require-Bundle: org.eclipse.xtend.lib.macro; bundle-version="2.36.0"; visibility:="reexport"
-> Bundle-SymbolicName: org.eclipse.xtend.lib.macro; bundle-version="2.36.0.v20240825-0714"
org.eclipse.xtend.lib.macro [1849]
No resolution report for the bundle. Unresolved requirement: Import-Package: org.apache.log4j; version="1.2.15"
-> Export-Package: org.apache.log4j; bundle-symbolic-name="org.apache.log4j"; bundle-version="1.2.15.v201012070815"; version="1.2.15"
Unresolved requirement: Require-Bundle: org.objectweb.asm; bundle-version="[9.1.0,9.2.0)"; resolution:="optional"
-> Bundle-SymbolicName: org.objectweb.asm; bundle-version="9.1.0.v20210209-1849"
org.objectweb.asm [2054]
No resolution report for the bundle. Unresolved requirement: Require-Bundle: org.eclipse.xtend.lib; resolution:="optional"
-> Bundle-SymbolicName: org.eclipse.xtend.lib; bundle-version="2.36.0.v20240825-0714"
Unresolved requirement: Import-Package: org.apache.log4j
-> Export-Package: org.apache.log4j; bundle-symbolic-name="org.apache.log4j"; bundle-version="1.2.15.v201012070815"; version="1.2.15"
Unresolved requirement: Require-Bundle: org.eclipse.xtext.util
-> Bundle-SymbolicName: org.eclipse.xtext.util; bundle-version="2.25.0.v20210301-0843"
Unresolved requirement: Require-Bundle: org.eclipse.xtend.lib
-> Bundle-SymbolicName: org.eclipse.xtend.lib; bundle-version="2.36.0.v20240825-0714"
Bundle was not resolved because of a uses constraint violation.
org.apache.felix.resolver.reason.ReasonException: Uses constraint violation. Unable to resolve resource org.eclipse.cbi.targetplatform [osgi.identity; type="osgi.bundle"; version:Version="3.1.0.202409011232"; osgi.identity="org.eclipse.cbi.targetplatform"; singleton:="true"] because it is exposed to package 'com.google.common.util.concurrent.internal' from resources com.google.guava [osgi.identity; type="osgi.bundle"; version:Version="30.1.0.v20221112-0806"; osgi.identity="com.google.guava"] and com.google.guava.failureaccess [osgi.identity; type="osgi.bundle"; version:Version="1.0.2"; osgi.identity="com.google.guava.failureaccess"] via two dependency chains.
Chain 1:
org.eclipse.cbi.targetplatform [osgi.identity; type="osgi.bundle"; version:Version="3.1.0.202409011232"; osgi.identity="org.eclipse.cbi.targetplatform"; singleton:="true"]
require: (osgi.wiring.bundle=org.eclipse.xtext)
|
provide: osgi.wiring.bundle: org.eclipse.xtext
com.google.guava [osgi.identity; type="osgi.bundle"; version:Version="30.1.0.v20221112-0806"; osgi.identity="com.google.guava"]
Chain 2:
org.eclipse.cbi.targetplatform [osgi.identity; type="osgi.bundle"; version:Version="3.1.0.202409011232"; osgi.identity="org.eclipse.cbi.targetplatform"; singleton:="true"]
require: (&(osgi.wiring.bundle=org.eclipse.xtext.xbase.lib)(bundle-version>=2.14.0))
|
provide: osgi.wiring.bundle; bundle-version:Version="2.37.0.v20241119-0857"; osgi.wiring.bundle="org.eclipse.xtext.xbase.lib"
com.google.guava [osgi.identity; type="osgi.bundle"; version:Version="33.3.1.jre"; osgi.identity="com.google.guava"]
import: (&(osgi.wiring.package=com.google.common.util.concurrent.internal)(&(version>=1.0.0)(!(version>=2.0.0))))
|
export: osgi.wiring.package: com.google.common.util.concurrent.internal
com.google.guava.failureaccess [osgi.identity; type="osgi.bundle"; version:Version="1.0.2"; osgi.identity="com.google.guava.failureaccess"]
at org.eclipse.osgi.container.Module.start(Module.java:493)
at org.eclipse.osgi.container.ModuleContainer$ContainerStartLevel$2.run(ModuleContainer.java:2102)
at org.eclipse.osgi.internal.framework.EquinoxContainerAdaptor$1$1.execute(EquinoxContainerAdaptor.java:143)
at org.eclipse.osgi.container.ModuleContainer$ContainerStartLevel.incStartLevel(ModuleContainer.java:2093)
at org.eclipse.osgi.container.ModuleContainer$ContainerStartLevel.incStartLevel(ModuleContainer.java:2033)
at org.eclipse.osgi.container.ModuleContainer$ContainerStartLevel.doContainerStartLevel(ModuleContainer.java:1996)
at org.eclipse.osgi.container.ModuleContainer$ContainerStartLevel.dispatchEvent(ModuleContainer.java:1912)
at org.eclipse.osgi.container.ModuleContainer$ContainerStartLevel.dispatchEvent(ModuleContainer.java:1)
at org.eclipse.osgi.framework.eventmgr.EventManager.dispatchEvent(EventManager.java:230)
at org.eclipse.osgi.framework.eventmgr.EventManager$EventThread.run(EventManager.java:341)
有谁能够解释这里出了什么问题,并指导我如何修复它,而无需完全重建 Eclipse?
我放弃了。我从头开始重新安装了 Eclipse(就像我每次更新时所做的那样),但是,我放弃了它作为我的主要开发环境,只将它用于一些遗留的东西,并安装了 VSCode(我的大多数同事都在使用它) )。我一直更喜欢 Eclipse,但它不再值得痛苦了。