The GitHub Actions job "Code Style" on grails-core.git/grails8-groovy6-canary has failed. Run started by GitHub user jamesfredley (triggered by jamesfredley).
Head commit for run: 8b349bcdb87c19b648a794107ce2fbe6c304f274 / James Fredley <[email protected]> fix(views-gson): work around Groovy 6 Verifier abstract-method regression (blocker #6) Under Groovy 6.0.0-SNAPSHOT, ClassCompletionVerifier.checkNoAbstractMethodsNonAbstractClass spuriously reports all 5 GrailsJsonViewHelper#render(...) overloads as unimplemented on DefaultGrailsJsonViewHelper, even though they are declared/overridden on the class. The check iterates ClassNode.getDeclaredMethodsMap() keyed by MethodNode.getTypeDescriptor() (which includes the return type); the concrete leaf render(...) overrides resolve a different return-type descriptor than the interface's abstract render(...) entries for the inner-class return type grails.plugin.json.builder.JsonOutput.JsonWritable, so they do not displace the abstract entries and survive as "unimplemented". (groovy.json.JsonOutput.JsonWritable, which the Grails inner class shadowed on Groovy 5, was removed on Groovy 6 - JsonOutput now only declares JsonUnescaped - which changes inner-class resolution.) It is a Verifier-layer defect, not the static type checker: it reproduces with @CompileStatic removed. Eleven earlier source-level workarounds were rejected (explicit forwarders, fully-qualified return types, inner-class rename, removing @CompileStatic from class and interface, explicit constructor, abstract-parent + concrete-subclass, @CompileDynamic, diamond removal, diamond + covariant-getG removal, and concrete render stubs on the intermediate superclass DefaultJsonViewHelper). The fix here targets the actual defect: the bug lives in the *abstract*-method check, so the 5 render(...) methods on GrailsJsonViewHelper are declared as `default` (concrete). They are then absent from getAbstractMethods(), the verifier has nothing to flag, and DefaultGrailsJsonViewHelper - the sole implementor - overrides all 5, so the throwing default bodies are never reached. Verified on Groovy 6.0.0-SNAPSHOT build #716 / Gradle 9.5.1 / Spring Boot 4.0.6: :grails-views-gson:compileGroovy -> green :grails-views-gson:test -> all pass (render / HAL / JSON-API / template-inheritance), 1 pre-existing @IgnoreIf skip :grails-views-gson:codeStyle -> green Remove once the upstream Groovy 6 Verifier regression is fixed. In-tree reproducer: grails-views-gson itself; a dependency-free standalone reproduction is still being isolated. Assisted-by: claude-code:claude-4.8-opus Report URL: https://github.com/apache/grails-core/actions/runs/26651939951 With regards, GitHub Actions via GitBox
