I was also getting this error after upgrading to 1.2.5, except that in
my case the javax.jdo.JDODetachedFieldAccessException was happening
when I tried to access a simple
'com.google.appengine.api.datastore.Text' field on a Detached object
(Datanucleus must be treating Enumerated fields like a Collection).

I'm using JPA, so for every Text in my entities I had to add the
annotation @Basic(fetch = FetchType.EAGER).  Just FYI, because I'd
never used a fetchtype on a non-collection field.

Not sure if this is how it's supposed to work, but it fixes the issue.

david


On Sep 10, 1:13 am, hansamann <sven.hai...@googlemail.com> wrote:
> Hi all,
>
> since I updated my app to the latest java sdk, I sometimes see these
> errors (which results in the homepage of the app being blank or
> showing an ugly error message):
>
> [groovytweets/73.336182399219449559].<stdout>: StackTrace Sanitizing
> stacktrace:
> org.codehaus.groovy.runtime.InvokerInvocationException:
> javax.jdo.JDODetachedFieldAccessException: You have just attempted to
> access field "retweets" yet this field was not detached when you
> detached the object. Either dont access this field, or detach it when
> detaching the object.
>         at org.codehaus.groovy.reflection.CachedMethod.invoke
> (CachedMethod.java:92)
>         at groovy.lang.MetaMethod.doMethodInvoke(MetaMethod.java:234)
>         at groovy.lang.MetaClassImpl.invokeMethod(MetaClassImpl.java:1062)
>         at groovy.lang.ExpandoMetaClass.invokeMethod(ExpandoMetaClass.java:
> 926)
>         at groovy.lang.MetaClassImpl.invokeMethod(MetaClassImpl.java:893)
>         at groovy.lang.Closure.call(Closure.java:279)
>         at org.codehaus.groovy.grails.web.pages.GroovyPage.invokeTag
> (GroovyPage.java:219)
>         at org.codehaus.groovy.grails.web.pages.GroovyPage$invokeTag
> $0.callCurrent(Unknown Source)
>         at
>

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Google App Engine for Java" group.
To post to this group, send email to google-appengine-java@googlegroups.com
To unsubscribe from this group, send email to 
google-appengine-java+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/google-appengine-java?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to