-
Notifications
You must be signed in to change notification settings - Fork 2.7k
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
Ensure that a non-indexed entry doesn't break generic type resolution #16727
Conversation
cc @lburgazzoli who initially brought this to me |
This workflow status is outdated as a new workflow run has been triggered. Failing Jobs - Building 6f1268a
Full information is available in the Build summary check run. Test Failures⚙️ JVM Tests - JDK 11 #📦 extensions/jdbc/jdbc-mysql/deployment✖ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sorry, I don't understand the change.
What I think this is doing is that for external callers to findParametersRecursively
this will still throw if not found, but if it recurses inside, it will return null
instead.
So… I assume fetchFromIndex
is the one doing the throwing, and then it will only throw for the first-level call, not for any recursion?
What external callers?
Yes, My whole point is that I don't want th exception to terminal when looking up superclasses or interfaces |
The function that calls it the first time. It's not going to just call itself ;)
OK. Got it. My only worry is that this is changing the behaviour for all users of that method, and so it may be hiding the cause of a further error. I think there are two cases where we can fail to find the parameter recursively:
I think you've treated the second case. I worry about the first case, because the result is that we'll tell the user we could not find the parameter (it will be OTOH, if the contract of the external caller to So perhaps the safer thing to do is to record which types are not indexed during recursion, and keep going. If at the end of the external call we have a result, then ignore all those not-indexed errors. If we don't, then raise an error explaining which types were not indexed that could be the cause of this error? WDYT? |
Yes, I completely agree
Sure yeah, that makes sense. I'll update the PR on Monday |
OK great, no rush :) |
6f1268a
to
553bf19
Compare
PR updated as per your suggestion and tests added |
This workflow status is outdated as a new workflow run has been triggered. Failing Jobs - Building 553bf19
Full information is available in the Build summary check run. Test Failures⚙️ JVM Tests - JDK 11 #📦 integration-tests/spring-web✖ ⚙️ JVM Tests - JDK 15 #📦 integration-tests/spring-web✖ ⚙️ MicroProfile TCKs Tests #📦 tcks/resteasy-reactive/target/testsuite/tests✖ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Great!
553bf19
to
a49d919
Compare
It seems like the failure in |
This can happen if say some interface extends a JDK interface and there is no reason the type resolution should fail because of it
a49d919
to
c06abd3
Compare
Fixed |
This workflow status is outdated as a new workflow run has been triggered. 🚫 This workflow run has been cancelled. Failing Jobs - Building a49d919
Full information is available in the Build summary check run. Test Failures⚙️ Devtools Tests - JDK 11 Windows #📦 integration-tests/devtools✖ ⚙️ MicroProfile TCKs Tests #📦 tcks/resteasy-reactive/target/testsuite/tests✖ |
Failing Jobs - Building c06abd3
Full information is available in the Build summary check run. Test Failures⚙️ JVM Tests - JDK 11 Windows #📦 extensions/arc/deployment✖ |
This can happen if say some interface extends a JDK interface and there
is no reason the type resolution should fail because of it