[
https://issues.apache.org/jira/browse/GROOVY-12577?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=18134541#comment-18134541
]
ASF GitHub Bot commented on GROOVY-12577:
-----------------------------------------
testlens-app[bot] commented on PR #3103:
URL: https://github.com/apache/groovy/pull/3103#issuecomment-6512267001
## 🚨 TestLens detected 1 failed test 🚨
### Test Summary
> [!TIP]
> Inspect all details with the [TestLens
CLI](https://testlens.app/docs/features/cli): `testlens pr 3103`
#### [Build and test / lts \(25,
ubuntu-latest\)](https://github.com/apache/groovy/actions/runs/40977375022/job/123808653476?pr=3103)
> :groovy-lsp:test
| Test | Runs | Flakiness |
|---|---|--:|
| GroovyLanguageServerTest >
publishDiagnosticsIncludeVersionAndClearRemovedUris\(\) | ❌ | 1% 🟡 |
🏷️ Commit: 5c48df220bab78575d1db1ecd9adc49303e480c9
▶️ Tests: 50704 executed
🟡 Checks: 8/24 completed
### Test Failures
<details><summary><strong>GroovyLanguageServerTest >
publishDiagnosticsIncludeVersionAndClearRemovedUris()</strong>
(:groovy-lsp:test in <a
href="https://github.com/apache/groovy/actions/runs/40977375022/job/123808653476?pr=3103">Build
and test / lts (25, ubuntu-latest)</a>)</summary>
```
java.util.ConcurrentModificationException
at
java.base/java.util.ArrayList$Itr.checkForComodification(ArrayList.java:1096)
at java.base/java.util.ArrayList$Itr.next(ArrayList.java:1050)
at
org.codehaus.groovy.runtime.ScriptBytecodeAdapter.getPropertySpreadSafe(ScriptBytecodeAdapter.java:508)
at
org.apache.groovy.lsp.GroovyLanguageServerTest.publishDiagnosticsIncludeVersionAndClearRemovedUris(GroovyLanguageServerTest.groovy:236)
```
</details>
### Rerun Controls
> [!NOTE]
> Checks are currently running using the configuration below.
Select tests to mute in this pull request:
🔲 GroovyLanguageServerTest >
publishDiagnosticsIncludeVersionAndClearRemovedUris\(\) <!
> SC: a method of Class called without a receiver in a static method fails
> verification
> -------------------------------------------------------------------------------------
>
> Key: GROOVY-12577
> URL: https://issues.apache.org/jira/browse/GROOVY-12577
> Project: Groovy
> Issue Type: Bug
> Components: Static compilation
> Affects Versions: 5.0.8, 6.0.0
> Reporter: Scott Murphy Heiberg
> Priority: Major
>
> {code:groovy}
> @groovy.transform.CompileStatic
> class C {
> static String m() { getSimpleName() }
> }
> C.m() // VerifyError: Bad local variable type ... C.m()Ljava/lang/String; @0:
> aload_0
> {code}
> In a static method or static initializer, {{this}} is the class object, and
> the type checker accepts a call to a method of {{Class}} without a receiver,
> like {{getName()}}, {{getSimpleName()}} or {{toString()}}. The static
> invocation writer treats the method as one of an enclosing class and loads
> {{Class.this}}, local variable 0, which does not exist in a static method.
> Methods of {{Object}}, such as {{hashCode()}}, work. 4.0.33 returns {{'C'}},
> as dynamic Groovy and an explicit {{this.getSimpleName()}} do.
> PR: https://github.com/apache/groovy/pull/3103
--
This message was sent by Atlassian Jira
(v10.3.26#10030026)