Gretty Needs Updating to Support Gradle 7

Gretty needs to be updated to support Gradle 7.


An exception occurred applying plugin request [id: ‘org.gretty’, version: ‘3.0.4’]
Failed to apply plugin ‘org.gretty’.
Cannot run Project.afterEvaluate(Closure) when the project is already evaluated.

From Gradle documentation:

Calling Project.afterEvaluate() after project evaluation is now an error

Gradle 6.x warns users about the wrong behavior and ignores the target action in this scenario.

Starting from 7.0 the same case will produce an error.

Plugins and build scripts should be adjusted to call afterEvaluate only at configuration time.
If you have such a build failure and the related afterEvaluate statement is declared in your build sources then you can simply delete it.
If afterEvaluate is declared in a plugin then report the issue to the plugin maintainers.

It’s in the making - Gretty has already a patch for the error you are describing, and this version is already available through snapshots. @ktaylor please join the discussion at gretty 3.0.4 doesn't work in gradle 7.0.2 · Issue #229 · gretty-gradle-plugin/gretty · GitHub.