Hacktoberfest 2026: le issue che i maintainer hanno segnato per ottobre, aperte e adatte ai principianti. Sfoglia le issue Hacktoberfest

java.lang.NoClassDefFoundError: java/applet/Applet on modern JDKs (Java 26+) due to legacy Applet references

Aperta
#281 0 commenti 0 reazioni 0 assegnatari Vedi su GitHub

Nessuno ha ancora preso questa issue.

Valutazione

Difficoltà
3/5
Tempo stimato
Mezza giornata
Idoneità per principianti
35/100
Tipo di issue
Bug
Chiarezza
Abbastanza chiara
Stato di attività
Attiva
Stack tecnologico
java
Ambito
testing

Direzione di ricerca

The stack trace points to BasePosRobotIT.setUpBase at line 83, which is in the reporter's own project, not in AssertJ Swing's sources. First, grep the repository for java.applet and JApplet references and run the test suite on JDK 26 to confirm where the missing class is loaded. If the reference only exists in the reporter's code, the fix belongs there, and the issue should be narrowed. Done when the cause is identified and either a library change or a clear out-of-scope conclusion is recorded.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

Description

When running UI automation tests built on top of AssertJ Swing under modern JDK environments, specifically JDK 26 or newer, the test suite crashes during initialization with a java.lang.NoClassDefFoundError targeting java/applet/Applet.

The Applet API has been completely removed from the standard JDK classpath in Java 26 under [JEP 504: Remove the Applet API].
Since AssertJ Swing still carries legacy references, internal fixtures, or utilities inherited from the original FEST Swing codebase that depend on java.applet.Applet, the framework fails immediately upon class loading.

Stack Trace
java.lang.NoClassDefFoundError: java/applet/Applet
	at io.github.kriolos.opos.automation.BasePosRobotIT.setUpBase(BasePosRobotIT.java:83)
	at java.base/java.lang.reflect.Method.invoke(Method.java:565)
	at java.base/java.util.ArrayList.forEach(ArrayList.java:1612)
Caused by: java.lang.ClassNotFoundException: java.applet.Applet
	at java.base/jdk.internal.loader.BuiltinClassLoader.loadClass(BuiltinClassLoader.java:580)
	at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:502)
Environment
  • Java Version: JDK 26+ (JEP 504 compliant)
  • OS: Agnostic
  • Library: AssertJ Swing (Core automation engine)
Expected Behavior

AssertJ Swing should be executable on modern standard runtimes (JDK 26+) without requiring or resolving deprecated and now-deleted packages like java.applet.*.

Suggested Fix
  1. Completely remove or refactor any code paths, modules, or internal test runners (such as legacy Applet viewers/fixtures) that reference java.applet.Applet or javax.swing.JApplet.
  2. Fully decouple standard desktop JFrame components from any Applet-based class loading mechanisms to restore compatibility with current and future JDK ecosystems.
Lingua principale
Java
Stelle
121
Fork
52
Metriche di merge delle PR
Nessuna PR unita negli ultimi 30g

Preparare l'ambiente

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di assertj/assertj-swing

Tutte le issue di assertj/assertj-swing

Issue simili

Altre issue su Java

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.