Skip to content

fix: restore 9.0.x CI after the 8.1.x merge-up - #16298

Open
jamesfredley wants to merge 3 commits into
9.0.xfrom
fix/9.0.x-ci-failures
Open

fix: restore 9.0.x CI after the 8.1.x merge-up#16298
jamesfredley wants to merge 3 commits into
9.0.xfrom
fix/9.0.x-ci-failures

Conversation

@jamesfredley

Copy link
Copy Markdown
Contributor

Description

Restores 9.0.x CI after merging 8.1.x. Before that merge, 9.0.x CI was already red on Forge (mainClassName) and publishMicronaut. The merge then added a Groovy 6 static-compile failure in GrailsWebDataBinder that took down Core, Forge, functional, Hibernate, MongoDB, Redis, Neo4j, Spring Security, and Code Style jobs.

This PR fixes the three unique root causes.

Groovy 6 collection binding compile

GrailsWebDataBinder now hoists item == null || referencedType.isAssignableFrom(...) into a boolean local, matching the existing array/map workaround. Groovy 6.0.0-beta-2 STC otherwise collapses || flow state inside the closure to void and fails with ArrayList#leftShift(void).

Verified: ./gradlew :grails-web-databinding:compileGroovy -PskipCodeStyle

Forge shadow scripts on Gradle 9.7.1

The Application plugin no longer has mainClassName. Setting that extra property made :grails-forge-web-netty:startShadowScripts fail with You can't map a property that does not exist: propertyName=mainClassName. The plugin now sets extra property mainClass.

Verified: cd grails-forge && ./gradlew :grails-forge-web-netty:startShadowScripts -PskipCodeStyle

Micronaut island is not on Groovy 6

settings.gradle only includes grails-micronaut / grails-micronaut-bom when the build uses Groovy 5. 9.0.x uses Groovy 6, so publishMicronaut and the matching release/reproducibility paths invoked missing projects. Those jobs and the dual-JDK Micronaut docs/scripts are removed on this branch.

Contributor Checklist

  • This PR addresses failing 9.0.x CI after the 8.1.x merge-up
  • This PR targets 9.0.x
  • Targeted compile/Forge verification passed locally
  • No unrelated reformatting

Hoist Groovy 6 collection-binding type checks out of || so STC no longer treats << item as leftShift(void). Set the Gradle extra property mainClass instead of removed mainClassName so Forge shadow scripts work on Gradle 9.7.1. Drop Micronaut island snapshot/release publishing on this Groovy 6 branch, where those projects are not in the graph.
Copilot AI lite review requested due to automatic review settings September 2, 2026 21:51

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🔵 Needs a closer look

It changes multiple CI/release workflows and reproducibility scripts, which warrants a final human verification pass despite no functional defects found in the reviewed hunks.

Pull request overview

Restores the 9.0.x branch CI after the 8.1.x merge-up by addressing three independent failures: a Groovy 6 STC compilation regression in GrailsWebDataBinder, a Gradle 9 Application plugin property change affecting Forge shadow start scripts, and removal of Micronaut “island” CI/release paths that are incompatible with the branch’s Groovy major.

Changes:

  • Adjust GrailsWebDataBinder collection/map binding to avoid Groovy 6 STC flow-state issues by hoisting || checks into a boolean local.
  • Update the Grails Gradle plugin to use mainClass (instead of removed mainClassName) for main-class propagation.
  • Remove Micronaut “island” dual-JDK/release/publish/reproducibility wiring from docs, scripts, and GitHub workflows on this branch.
File summaries
File Description
RELEASE.md Removes dual-JDK Micronaut “island” release/reproducibility documentation.
grails-web-databinding/src/main/groovy/grails/web/databinding/GrailsWebDataBinder.groovy Hoists `
grails-gradle/plugins/src/main/groovy/org/grails/gradle/plugin/core/GrailsGradlePlugin.groovy Switches extra property from mainClassName to mainClass to match Gradle 9 Application plugin.
etc/bin/verify.sh Removes JDK 25 preflight checks tied to the Micronaut “island”.
etc/bin/verify-reproducible.sh Drops the JDK 25 Micronaut “island” build/restore flow; now runs a single JDK pass.
etc/bin/test-reproducible-builds.sh Removes the JDK 25 Micronaut “island” pass and related env validation.
etc/bin/Dockerfile Removes installation of the secondary JDK 25 used for the Micronaut “island”.
.github/workflows/release.yml Removes JDK 25 Micronaut publish steps; aligns release flow with island exclusion on this branch.
.github/workflows/release-verify.yml Removes JDK 25 setup/export steps previously used for reproducible verification.
.github/workflows/gradle.yml Removes publishMicronaut job and updates snapshot publish commentary for island exclusion.
Review details
  • Files reviewed: 6/10 changed files
  • Comments generated: 1
  • Review effort level: Lite

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Comment thread .github/workflows/gradle.yml Outdated
@bito-code-review

Copy link
Copy Markdown

The comment in .github/workflows/gradle.yml should be updated to accurately reflect that the Micronaut-island pruning is conditional on both the JDK version and the Groovy major version. You can revise the comment to state: "settings.gradle prunes the Micronaut island if the JDK is older than 25 or the Groovy major version is not 5; this branch is pruned because it uses Groovy 6."

.github/workflows/gradle.yml

# settings.gradle prunes the Micronaut island if the JDK is older than 25
        # or the Groovy major version is not 5; this branch is pruned because it
        # uses Groovy 6.

@codecov

codecov Bot commented Sep 2, 2026

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 20.00000% with 4 lines in your changes missing coverage. Please review.
✅ Project coverage is 55.7202%. Comparing base (cb4941f) to head (9f208a8).
⚠️ Report is 36 commits behind head on 9.0.x.

Files with missing lines Patch % Lines
.../grails/web/databinding/GrailsWebDataBinder.groovy 0.0000% 0 Missing and 2 partials ⚠️
...rails/gradle/plugin/core/GrailsGradlePlugin.groovy 0.0000% 1 Missing ⚠️
...testing/mongo/StartMongoGrailsUnitExtension.groovy 0.0000% 1 Missing ⚠️
Additional details and impacted files

Impacted file tree graph

@@                 Coverage Diff                 @@
##                9.0.x     #16298         +/-   ##
===================================================
+ Coverage     30.1177%   55.7202%   +25.6025%     
- Complexity        519      21395      +20876     
===================================================
  Files              83       2147       +2064     
  Lines            4758     102618      +97860     
  Branches          815      18166      +17351     
===================================================
+ Hits             1433      57179      +55746     
- Misses           3082      37491      +34409     
- Partials          243       7948       +7705     
Files with missing lines Coverage Δ
...re/src/main/groovy/grails/boot/GrailsBanner.groovy 75.0000% <100.0000%> (ø)
...rails/gradle/plugin/core/GrailsGradlePlugin.groovy 0.0000% <0.0000%> (ø)
...testing/mongo/StartMongoGrailsUnitExtension.groovy 45.6522% <0.0000%> (ø)
.../grails/web/databinding/GrailsWebDataBinder.groovy 29.9320% <0.0000%> (ø)

... and 2061 files with indirect coverage changes

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

Accept pre-release groovy.version when selecting the snapshot canary branch so 6.0.0-beta-2 is not skipped for the Micronaut 5.x pin. Align GroovyPageAttributes subscript assignment with Groovy 6 Map.put semantics. Opt the end-to-end taglib harness out of Spock's Groovy version check.
Groovy 6 snapshot rejects List<String> and Map<String, Object> as class tokens. Use the raw types for Environment.getProperty and getDeclaredConstructor.
@testlens-app

testlens-app Bot commented Sep 3, 2026

Copy link
Copy Markdown

🚨 TestLens detected 1 failed test 🚨

Here is what you can do:

  1. Inspect the test failures carefully.
  2. If you are convinced that some of the tests are flaky, you can mute them below.
  3. Finally, trigger a rerun by checking the rerun checkbox.

Test Summary

CI / Functional Tests (Java 21, indy=true, shard 1) > :grails-test-examples-gsp-sitemesh3:integrationTest

Test Runs Flakiness
EndToEndSpec > async multiple levels of layouts 2% 🟡

🏷️ Commit: 9f208a8
▶️ Tests: 76542 executed
⚪️ Checks: 91/91 completed

Test Failures

EndToEndSpec > async multiple levels of layouts (:grails-test-examples-gsp-sitemesh3:integrationTest in CI / Functional Tests (Java 21, indy=true, shard 1))
Condition not satisfied:

pageSource == """<html><head><title>Decorated Base - Dialog - This is the title</title><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"></head> <body><h1>Hello</h1><div id="base"><div id="dialog">body text</div></div> </body></html>"""
|          |
|          false
|          Strings too large to calculate edit distance.
<html lang="en"><head><title>HTTP Status 500 – Internal Server Error</title><style type="text/css">body {font-family:Tahoma,Arial,sans-serif;} h1, h2, h3, b {color:white;background-color:#525D76;} h1 {font-size:22px;} h2 {font-size:16px;} h3 {font-size:14px;} p {font-size:12px;} a {color:black;} .line {height:1px;background-color:#525D76;border:none;}</style></head><body><h1>HTTP Status 500 – Internal Server Error</h1></body></html>

	at EndToEndSpec.async multiple levels of layouts(EndToEndSpec.groovy:107)
expected actual
<html><head><title>Decorated Base - Dialog - This is the title</title><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"></head> <html lang="en"><head><title>HTTP Status 500 Internal Server Error</title><style type="text/css">body {font-family:Tahoma,Arial,sans-serif;} h1, h2, h3, b {color:white;background-color:#525D76;} h1 {font-size:22px;} h2 {font-size:16px;} h3 {font-size:14px;} p {font-size:12px;} a {color:black;} .line {height:1px;background-color:#525D76;border:none;}</style></head><body><h1>HTTP Status 500 – Internal Server Error</h1></body></html>
<body><h1>Hello</h1><div id="base"><div id="dialog">body text</div></div>
</body></html>

Rerun Controls

Select tests to mute in this pull request:

  • EndToEndSpec > async multiple levels of layouts

Reuse successful test results:

  • ♻️ Only rerun the tests that failed or were muted before

Click the checkbox to trigger a rerun:

  • Rerun jobs

Learn more about TestLens at testlens.app/docs.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: No status

Development

Successfully merging this pull request may close these issues.

2 participants