Hello community, me again, Still try to upgrade o...
# questions
g
Hello community, me again, Still try to upgrade one of my products to grails 7, getting close, but still have issues: Now I have this error:
Copy code
Users_lei_[project_folder]_grails_app_views_layouts_main_gsp$_run_closure1$_closure9$_closure17.doCall(Users_[project_folder]_grails_app_views_layouts_main_gsp:24)
	at java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invoke(DirectMethodHandleAccessor.java:103)
	at org.grails.taglib.TagBodyClosure.executeClosure(TagBodyClosure.java:203)
	at org.grails.taglib.TagBodyClosure.captureClosureOutput(TagBodyClosure.java:105)
	at org.grails.taglib.TagBodyClosure.call(TagBodyClosure.java:216)
	at org.grails.plugins.web.taglib.GrailsLayoutTagLib.captureTagContent(GrailsLayoutTagLib.groovy:53)
	at org.grails.plugins.web.taglib.GrailsLayoutTagLib$_closure6.doCall(GrailsLayoutTagLib.groovy:213)
	at java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invoke(DirectMethodHandleAccessor.java:103)
	at org.grails.gsp.GroovyPage.invokeTagLibClosure(GroovyPage.java:449)
	at org.grails.gsp.GroovyPage.invokeTag(GroovyPage.java:367)
	at java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invoke(DirectMethodHandleAccessor.java:103)
	at org.codehaus.groovy.vmplugin.v8.IndyInterface.fromCache(IndyInterface.java:321)
	at Users_[project_folder]_grails_app_views_layouts_main_gsp$_run_closure1$_closure9.doCall(Users_[project_folder]_grails_app_views_layouts_main_gsp:27)
	at java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invoke(DirectMethodHandleAccessor.java:103)
	at org.grails.taglib.TagBodyClosure.executeClosure(TagBodyClosure.java:203)
	at org.grails.taglib.TagBodyClosure.captureClosureOutput(TagBodyClosure.java:105)
	at org.grails.taglib.TagBodyClosure.call(TagBodyClosure.java:216)
	at org.grails.plugins.web.taglib.GrailsLayoutTagLib$_closure7.doCall(GrailsLayoutTagLib.groovy:231)
	at java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invoke(DirectMethodHandleAccessor.java:103)
	at org.grails.gsp.GroovyPage.invokeTagLibClosure(GroovyPage.java:449)
	at org.grails.gsp.GroovyPage.invokeTag(GroovyPage.java:367)
	... 40 common frames omitted
Caused by: java.lang.NullPointerException: Cannot invoke "com.opensymphony.module.sitemesh.Page.getTitle()" because the return value of "org.codehaus.groovy.runtime.InvokerHelper.invokeMethodSafe(Object, String, Object)" is null
	at org.grails.plugins.web.taglib.RenderGrailsLayoutTagLib$_closure4.doCall(RenderGrailsLayoutTagLib.groovy:319)
	at java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invoke(DirectMethodHandleAccessor.java:103)
	at org.grails.gsp.GroovyPage.invokeTagLibClosure(GroovyPage.java:442)
	at org.grails.gsp.GroovyPage.invokeTag(GroovyPage.java:367)
	... 63 common frames omitted

Caused by: java.lang.NullPointerException: Cannot invoke "com.opensymphony.module.sitemesh.Page.getTitle()" because the return value of "org.codehaus.groovy.runtime.InvokerHelper.invokeMethodSafe(Object, String, Object)" is null
I am using sitemesh 2 with
Copy code
implementation "org.apache.grails:grails-layout"
I compared my project settings with a working grails 7 sample app(sitemesh2 and grails-layout), i can not tell difference BTW: I found claude code helped quite a bit when you do the upgrations.
Found the issues:
Copy code
runtimeOnly "org.grails.plugins:grails-web-console:7.0.0-RC1"
web-console need to be explicitly set to 7.0.0-RC1. (I believe the forge generated 7.0.0-M2), it contains |org.grailsgrails plugin sitemesh37.0.0-M3,
Copy code
implementation "org.grails.plugins:cache-ehcache:3.0.0"
needs to be commented off, This also bring
|    |    |    +--- org.grails:grails-plugin-sitemesh3:7.0.0-M3
back to the project
This screen shows how
claude code
helped me. It was very helpful.
🚀 1
🔥 1
j
https://github.com/apache/grails-core/pull/14981 - snapshot on start.grails.org has the updated version of web-console as of a few hours ago https://github.com/apache/grails-core/issues/14982 - issue for ehcache
👍 1
🙏 1
🙏🏻 1