quarkusio/quarkus · error · IllegalArgumentException
Unsupported annotation target
Error message
Unsupported annotation target
What it means
Generic build-time guard in the Qute ValueResolverGenerator: while generating a value resolver it encountered an annotation target kind it does not know how to process (not a method, field, or class accepted by the filter). This is effectively an internal unreachable-branch sentinel — the target kind at fault determines the failure, and it usually indicates an unsupported or malformed annotation placement on an endpoint or resolver candidate.
Source
Thrown at independent-projects/qute/generator/src/main/java/io/quarkus/qute/generator/ValueResolverGenerator.java:1019
}
}
static boolean defaultFilter(AnnotationTarget target) {
// Always ignore constructors, non-public members, synthetic and void methods
switch (target.kind()) {
case METHOD:
MethodInfo method = target.asMethod();
return Modifier.isPublic(method.flags())
&& !isSynthetic(method.flags())
&& method.returnType().kind() != org.jboss.jandex.Type.Kind.VOID
&& !method.isConstructor()
&& !method.isStaticInitializer();
case FIELD:
FieldInfo field = target.asField();
return Modifier.isPublic(field.flags())
&& !isSynthetic(field.flags());
default:
throw new IllegalArgumentException("Unsupported annotation target");
}
}
public static boolean isSynthetic(int mod) {
return (mod & 0x00001000) != 0;
}
public static boolean isGetterName(String name, Type returnType) {
if (name.startsWith(GET_PREFIX)) {
return true;
}
if (returnType == null
|| (returnType.name().equals(PrimitiveType.BOOLEAN.name()) || returnType.name().equals(DotNames.BOOLEAN))) {
return name.startsWith(IS_PREFIX) || name.startsWith(HAS_PREFIX);
}
return false;
}
View on GitHub (pinned to e1c734241f)
Solutions
- Check the annotation placement on the reported element — it must be on a public method, field, or class
- Avoid annotating constructors or synthetic members with Qute value-resolver annotations
- Report as a Quarkus bug if the target looks legitimate
Defensive patterns
Strategy: validation
When it happens
Trigger: Thrown at independent-projects/qute/generator/src/main/java/io/quarkus/qute/generator/ValueResolverGenerator.java:1019 when the library encounters an invalid state.
Common situations: See trigger scenarios.
AI-assisted analysis of quarkusio/quarkus@e1c734241f (2026-09-05).
Data as JSON: /api/errors/0f50fadb0be2c681.
Report an issue: GitHub.