SInce Gradle 7.x java.lang.ClassNotFoundException: org.apache.groovy.nio.extensions.NioExtensions

We use composite build to build and use gradle plugins and some shared libraries.
Something like this:

includeBuild “${gradle.ext.viewRoot}/QBuildSystemCore/qbsc”

gradle.rootProject { Project root →

root.beforeEvaluate { Project p ->
    p.buildscript.dependencies.add("classpath", "com.amat.gradle:qbsc-plugins:1.0")

Somewhere else in one or more build script we use the compiled code:
repositories {

maven {
    // this is how we use the composite build code
    url IToolConfig.get(project).artifactsM.mavenAllURL
    allowInsecureProtocol = true


The compsite build is Grooy+Java compiled with
plugins {
id ‘groovy’
id ‘java-gradle-plugin’

This works great since Gradle 4,5,6.
Now we are trying to move to Gradle 7.3.1
The code above
url IToolConfig.get(project).artifactsM.mavenAllURL

Causes an exception

     at org.gradle.groovy.scripts.internal.DefaultScriptRunnerFactory$
    ... 227 more

Caused by: java.lang.ClassNotFoundException: org.apache.groovy.nio.extensions.NioExtensions
… 281 more

Some more info, finnaly I found the “problematic” code
This is resolved into:

Replacing it , solves the problem, of course this is not solution, I can’t replace all usage of groovy methods

Applied Materials, DevOps Architect