Open famod opened 9 months ago
/cc @geoand (testing), @stuartwdouglas (continuous-testing)
I just found out it worked with 3.1.3.Final and broke with 3.2.0.CR1.
Reverting https://github.com/quarkusio/quarkus/commit/13103ee74ae88b8ad4610057df127e485389fb9a fixes it! So for this to work, the TCCL has to be set before every test.
It also fixes my non-inner class case (which had other issues after adding public
).
/cc @stuartwdouglas
The mentioned commit has this note:
This prevents extensions from modifying the TCCL. The correct TCCL is set at the start of the run.
I'm wondering whether we had any concrete issues with specific extensions. The PR doesn't link anything in that regard.
/cc @geoand Also /cc @holly-cummins, I've seen you fighting various test classloading related issues in the past. :slightly_smiling_face:
I'm wondering whether we had any concrete issues with specific extensions. The PR doesn't link anything in that regard.
Yeah, I am wondering the same...
FWIW, reverting causes a couple of test failures in ComponentContinuousTestingTest
(which I haven't looked at in detail yet).
FWIW, reverting causes a couple of test failures in
ComponentContinuousTestingTest
(which I haven't looked at in detail yet).
I think this is the root cause of that test failure (after the revert):
java.lang.IllegalArgumentException: Annotation is not a registered qualifier: interface jakarta.enterprise.inject.Any
at io.quarkus.arc.impl.Qualifiers.verifyQualifier(Qualifiers.java:152)
at io.quarkus.arc.impl.Qualifiers.verify(Qualifiers.java:47)
at io.quarkus.arc.impl.ArcContainerImpl.resolveObserverMethods(ArcContainerImpl.java:881)
at io.quarkus.arc.impl.EventImpl.createNotifier(EventImpl.java:182)
at io.quarkus.arc.impl.ArcContainerImpl.notifierOrNull(ArcContainerImpl.java:513)
at io.quarkus.arc.impl.ArcContainerImpl.<init>(ArcContainerImpl.java:206)
at io.quarkus.arc.Arc.initialize(Arc.java:38)
at io.quarkus.arc.Arc.initialize(Arc.java:22)
at io.quarkus.test.component.QuarkusComponentTestExtension.startContainer(QuarkusComponentTestExtension.java:401)
at io.quarkus.test.component.QuarkusComponentTestExtension.beforeEach(QuarkusComponentTestExtension.java:231)
at java.base/java.util.ArrayList.forEach(ArrayList.java:1511)
at java.base/java.util.ArrayList.forEach(ArrayList.java:1511)
/cc @mkouba
FWIW, reverting causes a couple of test failures in
ComponentContinuousTestingTest
(which I haven't looked at in detail yet).I think this is the root cause of that test failure (after the revert):
java.lang.IllegalArgumentException: Annotation is not a registered qualifier: interface jakarta.enterprise.inject.Any at io.quarkus.arc.impl.Qualifiers.verifyQualifier(Qualifiers.java:152) at io.quarkus.arc.impl.Qualifiers.verify(Qualifiers.java:47) at io.quarkus.arc.impl.ArcContainerImpl.resolveObserverMethods(ArcContainerImpl.java:881) at io.quarkus.arc.impl.EventImpl.createNotifier(EventImpl.java:182) at io.quarkus.arc.impl.ArcContainerImpl.notifierOrNull(ArcContainerImpl.java:513) at io.quarkus.arc.impl.ArcContainerImpl.<init>(ArcContainerImpl.java:206) at io.quarkus.arc.Arc.initialize(Arc.java:38) at io.quarkus.arc.Arc.initialize(Arc.java:22) at io.quarkus.test.component.QuarkusComponentTestExtension.startContainer(QuarkusComponentTestExtension.java:401) at io.quarkus.test.component.QuarkusComponentTestExtension.beforeEach(QuarkusComponentTestExtension.java:231) at java.base/java.util.ArrayList.forEach(ArrayList.java:1511) at java.base/java.util.ArrayList.forEach(ArrayList.java:1511)
/cc @mkouba
Well, I don't think there's something we could fix in ArC or in QuarkusComponentTest :shrug:.
Hi @holly-cummins, this might be something for https://github.com/orgs/quarkusio/projects/30
Describe the bug
The following primitive test (and tested class):
works fine in IDE or mvn, but fails with
mvn quarkus:test
:Expected behavior
No failure, should work as in IDE or mvn.
Actual behavior
Fails with classloading issue.
How to Reproduce?
mvn clean verify
(passes)mvn quarkus:test
failsOutput of
uname -a
orver
No response
Output of
java -version
No response
Quarkus version or git rev
3.7.4
Build tool (ie. output of
mvnw --version
orgradlew --version
)No response
Additional information
The problem vanishes after adding
public
to the inner class.I have another case where adding
public
helps, but that's not an inner class.It has been an issue for many releases now, I just haven't found the time to report it. I'm rather sure (IIRC) it was actually working some months ago.