-
Notifications
You must be signed in to change notification settings - Fork 46
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
[BUG] Property resolution leads to SEGV when POM has no own props #390
Comments
@ascheman thank you for filling this bug! Do you want to give it a shot and fix it? Otherwise I'll pick it up. |
Thanks for picking this up, @jmle - I have a workaround in progress (at least to avoid the SEGV) and can contribute it soon. In general I would be happy to provide a test case to avoid regressions for this in the future, and of course a full solution. But I need some more time to set this up. Therefore I would appreciate some help. |
Cool @ascheman, feel free to ask any questions in the #konveyor-dev slack channel |
Would be happy to proceed there: https://kubernetes.slack.com/archives/C04QZJFQ0UA/p1698750038252959 |
CAUTION: The property search should be extended to the parent POM (hierarchy).
CAUTION: The property search should be extended to the parent POM (hierarchy). Signed-off-by: Gerd Aschemann <gerd@aschemann.net>
CAUTION: The property search should be extended to the parent POM (hierarchy). Signed-off-by: Gerd Aschemann <gerd@aschemann.net>
CAUTION: The property search should be extended to the parent POM (hierarchy). Signed-off-by: Gerd Aschemann <gerd@aschemann.net>
Signed-off-by: Gerd Aschemann <gerd@aschemann.net>
Signed-off-by: Gerd Aschemann <gerd@aschemann.net>
Signed-off-by: Gerd Aschemann <gerd@aschemann.net>
Signed-off-by: Gerd Aschemann <gerd@aschemann.net>
Signed-off-by: Gerd Aschemann <gerd@aschemann.net>
Signed-off-by: Gerd Aschemann <gerd@aschemann.net>
It is hard to reproduce this error now - it only occurs during fallback resolution of POM dependencies which is no longer the case when Will try to provide a unit test for this. |
Signed-off-by: Gerd Aschemann <gerd@aschemann.net>
…eyor#420). Signed-off-by: Gerd Aschemann <gerd@aschemann.net>
Signed-off-by: Gerd Aschemann <gerd@aschemann.net>
Signed-off-by: Gerd Aschemann <gerd@aschemann.net>
Signed-off-by: Gerd Aschemann <gerd@aschemann.net>
Signed-off-by: Gerd Aschemann <gerd@aschemann.net>
Signed-off-by: Gerd Aschemann <gerd@aschemann.net>
…eyor#420). Signed-off-by: Gerd Aschemann <gerd@aschemann.net>
Signed-off-by: Gerd Aschemann <gerd@aschemann.net>
Signed-off-by: Gerd Aschemann <gerd@aschemann.net>
Signed-off-by: Gerd Aschemann <gerd@aschemann.net>
Signed-off-by: Gerd Aschemann <gerd@aschemann.net>
…eyor#420). Signed-off-by: Gerd Aschemann <gerd@aschemann.net>
Signed-off-by: Gerd Aschemann <gerd@aschemann.net>
Signed-off-by: Gerd Aschemann <gerd@aschemann.net>
Signed-off-by: Gerd Aschemann <gerd@aschemann.net>
Signed-off-by: Gerd Aschemann <gerd@aschemann.net>
…eyor#420). Signed-off-by: Gerd Aschemann <gerd@aschemann.net>
Signed-off-by: Gerd Aschemann <gerd@aschemann.net>
Signed-off-by: Gerd Aschemann <gerd@aschemann.net>
…eyor#420). Signed-off-by: Gerd Aschemann <gerd@aschemann.net>
Signed-off-by: Gerd Aschemann <gerd@aschemann.net>
Signed-off-by: Gerd Aschemann <gerd@aschemann.net>
Signed-off-by: Gerd Aschemann <gerd@aschemann.net>
Signed-off-by: Gerd Aschemann <gerd@aschemann.net>
…eyor#420). Signed-off-by: Gerd Aschemann <gerd@aschemann.net>
Signed-off-by: Gerd Aschemann <gerd@aschemann.net>
Adding test cases for #390. The Java example was refactored to make it run (i.e., `mvn compile` at least), and extended by a submodule. The submodule contains a property based dependency version which cannot be immediately resolved, as there is no `properties` definition in the submodule itself. The hotfix provided by #425 prevents the binary from failing. Nevertheless, the version property should be resolved from the parent pom which is not yet addressed. As the bug report only was about the SEGV caused by the problem, #390 may be closed anyway. --------- Signed-off-by: Gerd Aschemann <gerd@aschemann.net>
Is there an existing issue for this?
Konveyor version
How can I get it? I am using Analyzer-LSP directly!
Priority
Blocker
Current Behavior
When analysing a Java POM with a dependency as a property, analyzer tries to resolve the property in the same POM. If the POM contains no properties at all, this leads to a segmentation violation (in line 141 of
provider/internal/java/dependeny.go
):Expected Behavior
Try to resolve property via parent POM (hierarchy) or leave unresolved otherwise (which is the default, if the property cannot be found in an existing POM property list).
How Reproducible
Always (Default)
Steps To Reproduce
Prepare a project with POM like this.
And analyze it.
Environment
Anything else?
No response
The text was updated successfully, but these errors were encountered: