FYI, if I modify to: @Override public String saveTriggered() { getRequestContext().edit(getValue()); getValue().setActive(!view.isPracticeDeactivated()); save(); return null; }
still throws Reduced test case: final Driver driver = GWT.create(Driver.class); driver.initialize(requests, view); requests.find(handle.stableId()).with(driver.getPaths()).fire(chain.add(new Receiver<PracticeHandle>() { @Override public void onSuccess(final PracticeHandle response) { final PracticeRequest rc = requests.practiceRequest(); rc.edit(response); response.setActive(false); // Throws IllegalStateException } })); On Thu, Oct 7, 2010 at 5:27 PM, Patrick Julien <pjul...@gmail.com> wrote: > And I might add, otherwise the flush would fail, values coming from > the editors directly are fine > > On Thu, Oct 7, 2010 at 5:25 PM, Patrick Julien <pjul...@gmail.com> wrote: >> Yes, I know, rc.edit() is called, this is just before the flush, >> rc.edit has been called well before this. >> >> On Thu, Oct 7, 2010 at 5:23 PM, BobV <b...@google.com> wrote: >>> On Thu, Oct 7, 2010 at 1:55 PM, Patrick Julien <pjul...@gmail.com> wrote: >>>> They stay frozen, and finally, when flushing the driver, there is yet >>>> another loop to freeze all the AutoBeans. Nowhere in between were the >>>> beans made mutable. This is necessary because we sometimes have >>>> custom setters we must call. In this case, we have the following: >>> >>> This is as designed. All mutations to EntityProxy objects must be be >>> accumulated somewhere in order to be sent to the server. That >>> somewhere is the RequestContext. It's always necessary to call >>> RequestContext.edit() before mutating an EntityProxy. >>> >>> -- >>> Bob Vawter >>> Google Web Toolkit Team >>> >>> -- >>> http://groups.google.com/group/Google-Web-Toolkit-Contributors >> > -- http://groups.google.com/group/Google-Web-Toolkit-Contributors