[ https://issues.apache.org/jira/browse/GROOVY-9530?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17945873#comment-17945873 ]
ASF GitHub Bot commented on GROOVY-9530: ---------------------------------------- codecov-commenter commented on PR #2201: URL: https://github.com/apache/groovy/pull/2201#issuecomment-2816769847 ## [Codecov](https://app.codecov.io/gh/apache/groovy/pull/2201?dropdown=coverage&src=pr&el=h1&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) Report Attention: Patch coverage is `64.70588%` with `6 lines` in your changes missing coverage. Please review. > Project coverage is 68.9391%. Comparing base [(`6302c23`)](https://app.codecov.io/gh/apache/groovy/commit/6302c23b18c917afe099288f8ed969ffabe01d42?dropdown=coverage&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) to head [(`35e4f87`)](https://app.codecov.io/gh/apache/groovy/commit/35e4f871ef1efb7b8b9eafd8c79cc702f70a69d0?dropdown=coverage&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache). > Report is 2 commits behind head on master. | [Files with missing lines](https://app.codecov.io/gh/apache/groovy/pull/2201?dropdown=coverage&src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | Patch % | Lines | |---|---|---| | [...a/org/apache/groovy/ast/tools/ExpressionUtils.java](https://app.codecov.io/gh/apache/groovy/pull/2201?src=pr&el=tree&filepath=src%2Fmain%2Fjava%2Forg%2Fapache%2Fgroovy%2Fast%2Ftools%2FExpressionUtils.java&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache#diff-c3JjL21haW4vamF2YS9vcmcvYXBhY2hlL2dyb292eS9hc3QvdG9vbHMvRXhwcmVzc2lvblV0aWxzLmphdmE=) | 62.5000% | [0 Missing and 6 partials :warning: ](https://app.codecov.io/gh/apache/groovy/pull/2201?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | <details><summary>Additional details and impacted files</summary> [](https://app.codecov.io/gh/apache/groovy/pull/2201?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) ```diff @@ Coverage Diff @@ ## master #2201 +/- ## ================================================== - Coverage 68.9406% 68.9391% -0.0015% - Complexity 29550 29552 +2 ================================================== Files 1423 1423 Lines 113901 113902 +1 Branches 19753 19757 +4 ================================================== - Hits 78524 78523 -1 - Misses 28775 28777 +2 Partials 6602 6602 ``` | [Files with missing lines](https://app.codecov.io/gh/apache/groovy/pull/2201?dropdown=coverage&src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | Coverage Δ | | |---|---|---| | [...s/groovy/ast/decompiled/MemberSignatureParser.java](https://app.codecov.io/gh/apache/groovy/pull/2201?src=pr&el=tree&filepath=src%2Fmain%2Fjava%2Forg%2Fcodehaus%2Fgroovy%2Fast%2Fdecompiled%2FMemberSignatureParser.java&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache#diff-c3JjL21haW4vamF2YS9vcmcvY29kZWhhdXMvZ3Jvb3Z5L2FzdC9kZWNvbXBpbGVkL01lbWJlclNpZ25hdHVyZVBhcnNlci5qYXZh) | `97.1014% <100.0000%> (ø)` | | | [...a/org/apache/groovy/ast/tools/ExpressionUtils.java](https://app.codecov.io/gh/apache/groovy/pull/2201?src=pr&el=tree&filepath=src%2Fmain%2Fjava%2Forg%2Fapache%2Fgroovy%2Fast%2Ftools%2FExpressionUtils.java&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache#diff-c3JjL21haW4vamF2YS9vcmcvYXBhY2hlL2dyb292eS9hc3QvdG9vbHMvRXhwcmVzc2lvblV0aWxzLmphdmE=) | `77.1277% <62.5000%> (-0.9472%)` | :arrow_down: | ... and [3 files with indirect coverage changes](https://app.codecov.io/gh/apache/groovy/pull/2201/indirect-changes?src=pr&el=tree-more&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) </details> <details><summary> :rocket: New features to boost your workflow: </summary> - :snowflake: [Test Analytics](https://docs.codecov.com/docs/test-analytics): Detect flaky tests, report on failures, and find test suite problems. - :package: [JS Bundle Analysis](https://docs.codecov.com/docs/javascript-bundle-analysis): Save yourself from yourself by tracking and limiting bundle sizes in JS merges. </details> > Groovy compiler inlines constants from precompiled classes when it's not safe > to do so > -------------------------------------------------------------------------------------- > > Key: GROOVY-9530 > URL: https://issues.apache.org/jira/browse/GROOVY-9530 > Project: Groovy > Issue Type: Bug > Components: Compiler > Affects Versions: 3.0.3, 2.5.11 > Reporter: Marcin Erdmann > Assignee: Eric Milles > Priority: Major > > When a constant (a {{static final}} field) from a precompiled class (a class > which is on compilation classpath) is referenced from a declaration of a > {{static final}} field in a class which is being compiled the compiler will > load and initialise the precompiled class during compilation and inline the > value of the referenced constant even if it is not safe to do so, like for > example if the value of the constant depends on the contents of the classpath > at runtime. > The issue does not happen in Groovy 2.4.19 but happens in 2.5.11 and 3.0.3 > The following project exposes the issue: > https://github.com/erdi/groovy-constant-inlining-bug. If you run {{./gradlew > :test}} which uses Groovy 2.4.19 it will pass but it will fail if you run > {{./gradlew :testGroovy2_5}} or {{./gradlew testGroovy3_0}}. > I believe the problem lies in > {{org.apache.groovy.ast.tools.ExpressionUtils#transformInlineConstants(org.codehaus.groovy.ast.expr.Expression, > org.codehaus.groovy.ast.ClassNode)}} when handling property expressions on > non primary class nodes. -- This message was sent by Atlassian Jira (v8.20.10#820010)