Re: [T5.1.0.0] Loop in Form problem introduced in T5.1.0.0

2009-03-18 Thread Joost Schouten (mailing lists)
Howard,

I had a closer look to volatile in the Loop. Though I don't fully get
all the details yet, I don't see why the Form still needs to execute
any ComponentAction on the Loop when volatile=true. Why does
advanceVolatile need to access the Loop's iterator?

When I remove items from the loop through ajax, this causes a
NoSuchElementException like listed below.

Looking forward to your reply cuz I'm lost.
Cheers,
Joost

On Fri, Mar 13, 2009 at 11:55 AM, Joost Schouten (mailing lists)
 wrote:
> Howard,
>
> So why do I get the following exception when I set volatile=true? It
> only happens when my Ajax request removes some of the Loop items. It
> sounds like Tapestry is still trying to do some sort of state
> recovery.
>
> Cheers,
> Joost
>
> - exception -
>
> Caused by: java.util.NoSuchElementException
>       at java.util.AbstractList$Itr.next(AbstractList.java:427)
>       at 
> org.apache.tapestry5.corelib.components.Loop.advanceVolatile(Loop.java:335)
>       at org.apache.tapestry5.corelib.components.Loop.access$200(Loop.java:41)
>       at org.apache.tapestry5.corelib.components.Loop$3.execute(Loop.java:92)
>       at org.apache.tapestry5.corelib.components.Loop$3.execute(Loop.java:96)
>       at 
> org.apache.tapestry5.corelib.components.Form.executeStoredActions(Form.java:471)
>       ... 81 more
>
> Thanks for you quick response. I added the param but now get a new
> Exception (see below). The exception still only happens when elements
> are removed from the Loop through AJAX, adding all works fine. This
> whole volatile concept is a bit fuzzy to me and scanning the source of
> the Loop component does not clear things up to me. Do you have any
> further pointers?
>
> Cheers,
> Joost
>
> --- the new Exception --
>
>
>
> On Thu, Mar 12, 2009 at 11:55 PM, Howard Lewis Ship  wrote:
>> That what volatile is supposed to do; when set to true, the Loop
>> doesn't record its state (i.e., the series of values iterated over)
>> into the form data.
>>
>> On Thu, Mar 12, 2009 at 3:20 AM, Joost Schouten (mailing lists)
>>  wrote:
>>> Hi,
>>>
>>> AjaxFormLoop seems intended for formitems and would require a lot of
>>> javascript wiring to make it do what I want it to do. All I need is
>>> for the Form to completely ignore the Loop, just like it did nicely in
>>> 5.0.18. Do you know why the Loop's state needs to be persisted in the
>>> first place? And why can I not tell it to be completely ignored by the
>>> Form?
>>>
>>> It seems to me that all this state saving on a loop is needed if there
>>> are formitems in the loop. If so, it'd be great if I could just ignore
>>> the whole state saving and use the Loop in a nice and simple way by
>>> setting something like ignoreForm=true.
>>>
>>> Cheers,
>>> Joost
>>>
>>> On Tue, Mar 10, 2009 at 1:29 PM, DH  wrote:
>>>> Hi,
>>>>
>>>> In your case, why not have a try on AjaxFormLoop component, but I haven't 
>>>> tried this component yet and don't have much experience.
>>>>
>>>> Loop component in form is a bit tricky. Set volatile='true' means you need 
>>>> have your source object unchanged. But you have deleted one row during 
>>>> process, so exception happens.
>>>>
>>>> Thanks
>>>>
>>>> DH
>>>>
>>>>
>>>> - Original Message -
>>>> From: "Joost Schouten (mailing lists)" 
>>>> To: "Tapestry users" 
>>>> Sent: Tuesday, March 10, 2009 11:13 AM
>>>> Subject: Re: [T5.1.0.0] Loop in Form problem introduced in T5.1.0.0
>>>>
>>>>
>>>> Dear DH,
>>>>
>>>> Thanks for you quick response. I added the param but now get a new
>>>> Exception (see below). The exception still only happens when elements
>>>> are removed from the Loop through AJAX, adding all works fine. This
>>>> whole volatile concept is a bit fuzzy to me and scanning the source of
>>>> the Loop component does not clear things up to me. Do you have any
>>>> further pointers?
>>>>
>>>> Cheers,
>>>> Joost
>>>>
>>>> --- the new Exception --
>>>>
>>>> Caused by: java.util.NoSuchElementException
>>>> at java.util.AbstractList$Itr.next(AbstractList.java:427)
>>>> at 
>>>> org.apache.tapestry5.corelib.components.Loop.advanceVolatile(Loop.java:335)
>>&g

Re: [T5.1.0.0] Loop in Form problem introduced in T5.1.0.0

2009-03-12 Thread Joost Schouten (mailing lists)
Howard,

So why do I get the following exception when I set volatile=true? It
only happens when my Ajax request removes some of the Loop items. It
sounds like Tapestry is still trying to do some sort of state
recovery.

Cheers,
Joost

- exception -

Caused by: java.util.NoSuchElementException
   at java.util.AbstractList$Itr.next(AbstractList.java:427)
   at 
org.apache.tapestry5.corelib.components.Loop.advanceVolatile(Loop.java:335)
   at org.apache.tapestry5.corelib.components.Loop.access$200(Loop.java:41)
   at org.apache.tapestry5.corelib.components.Loop$3.execute(Loop.java:92)
   at org.apache.tapestry5.corelib.components.Loop$3.execute(Loop.java:96)
   at 
org.apache.tapestry5.corelib.components.Form.executeStoredActions(Form.java:471)
   ... 81 more

Thanks for you quick response. I added the param but now get a new
Exception (see below). The exception still only happens when elements
are removed from the Loop through AJAX, adding all works fine. This
whole volatile concept is a bit fuzzy to me and scanning the source of
the Loop component does not clear things up to me. Do you have any
further pointers?

Cheers,
Joost

--- the new Exception --



On Thu, Mar 12, 2009 at 11:55 PM, Howard Lewis Ship  wrote:
> That what volatile is supposed to do; when set to true, the Loop
> doesn't record its state (i.e., the series of values iterated over)
> into the form data.
>
> On Thu, Mar 12, 2009 at 3:20 AM, Joost Schouten (mailing lists)
>  wrote:
>> Hi,
>>
>> AjaxFormLoop seems intended for formitems and would require a lot of
>> javascript wiring to make it do what I want it to do. All I need is
>> for the Form to completely ignore the Loop, just like it did nicely in
>> 5.0.18. Do you know why the Loop's state needs to be persisted in the
>> first place? And why can I not tell it to be completely ignored by the
>> Form?
>>
>> It seems to me that all this state saving on a loop is needed if there
>> are formitems in the loop. If so, it'd be great if I could just ignore
>> the whole state saving and use the Loop in a nice and simple way by
>> setting something like ignoreForm=true.
>>
>> Cheers,
>> Joost
>>
>> On Tue, Mar 10, 2009 at 1:29 PM, DH  wrote:
>>> Hi,
>>>
>>> In your case, why not have a try on AjaxFormLoop component, but I haven't 
>>> tried this component yet and don't have much experience.
>>>
>>> Loop component in form is a bit tricky. Set volatile='true' means you need 
>>> have your source object unchanged. But you have deleted one row during 
>>> process, so exception happens.
>>>
>>> Thanks
>>>
>>> DH
>>>
>>>
>>> - Original Message -
>>> From: "Joost Schouten (mailing lists)" 
>>> To: "Tapestry users" 
>>> Sent: Tuesday, March 10, 2009 11:13 AM
>>> Subject: Re: [T5.1.0.0] Loop in Form problem introduced in T5.1.0.0
>>>
>>>
>>> Dear DH,
>>>
>>> Thanks for you quick response. I added the param but now get a new
>>> Exception (see below). The exception still only happens when elements
>>> are removed from the Loop through AJAX, adding all works fine. This
>>> whole volatile concept is a bit fuzzy to me and scanning the source of
>>> the Loop component does not clear things up to me. Do you have any
>>> further pointers?
>>>
>>> Cheers,
>>> Joost
>>>
>>> --- the new Exception --
>>>
>>> Caused by: java.util.NoSuchElementException
>>> at java.util.AbstractList$Itr.next(AbstractList.java:427)
>>> at 
>>> org.apache.tapestry5.corelib.components.Loop.advanceVolatile(Loop.java:335)
>>> at org.apache.tapestry5.corelib.components.Loop.access$200(Loop.java:41)
>>> at org.apache.tapestry5.corelib.components.Loop$3.execute(Loop.java:92)
>>> at org.apache.tapestry5.corelib.components.Loop$3.execute(Loop.java:96)
>>> at 
>>> org.apache.tapestry5.corelib.components.Form.executeStoredActions(Form.java:471)
>>> ... 81 more
>>>
>>
>> -
>> To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
>> For additional commands, e-mail: users-h...@tapestry.apache.org
>>
>>
>
>
>
> --
> Howard M. Lewis Ship
>
> Creator Apache Tapestry and Apache HiveMind
>
> -
> To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
> For additional commands, e-mail: users-h...@tapestry.apache.org
>
>

-
To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
For additional commands, e-mail: users-h...@tapestry.apache.org



Re: [T5.1.0.0] Loop in Form problem introduced in T5.1.0.0

2009-03-12 Thread Howard Lewis Ship
That what volatile is supposed to do; when set to true, the Loop
doesn't record its state (i.e., the series of values iterated over)
into the form data.

On Thu, Mar 12, 2009 at 3:20 AM, Joost Schouten (mailing lists)
 wrote:
> Hi,
>
> AjaxFormLoop seems intended for formitems and would require a lot of
> javascript wiring to make it do what I want it to do. All I need is
> for the Form to completely ignore the Loop, just like it did nicely in
> 5.0.18. Do you know why the Loop's state needs to be persisted in the
> first place? And why can I not tell it to be completely ignored by the
> Form?
>
> It seems to me that all this state saving on a loop is needed if there
> are formitems in the loop. If so, it'd be great if I could just ignore
> the whole state saving and use the Loop in a nice and simple way by
> setting something like ignoreForm=true.
>
> Cheers,
> Joost
>
> On Tue, Mar 10, 2009 at 1:29 PM, DH  wrote:
>> Hi,
>>
>> In your case, why not have a try on AjaxFormLoop component, but I haven't 
>> tried this component yet and don't have much experience.
>>
>> Loop component in form is a bit tricky. Set volatile='true' means you need 
>> have your source object unchanged. But you have deleted one row during 
>> process, so exception happens.
>>
>> Thanks
>>
>> DH
>>
>>
>> - Original Message -
>> From: "Joost Schouten (mailing lists)" 
>> To: "Tapestry users" 
>> Sent: Tuesday, March 10, 2009 11:13 AM
>> Subject: Re: [T5.1.0.0] Loop in Form problem introduced in T5.1.0.0
>>
>>
>> Dear DH,
>>
>> Thanks for you quick response. I added the param but now get a new
>> Exception (see below). The exception still only happens when elements
>> are removed from the Loop through AJAX, adding all works fine. This
>> whole volatile concept is a bit fuzzy to me and scanning the source of
>> the Loop component does not clear things up to me. Do you have any
>> further pointers?
>>
>> Cheers,
>> Joost
>>
>> --- the new Exception --
>>
>> Caused by: java.util.NoSuchElementException
>> at java.util.AbstractList$Itr.next(AbstractList.java:427)
>> at 
>> org.apache.tapestry5.corelib.components.Loop.advanceVolatile(Loop.java:335)
>> at org.apache.tapestry5.corelib.components.Loop.access$200(Loop.java:41)
>> at org.apache.tapestry5.corelib.components.Loop$3.execute(Loop.java:92)
>> at org.apache.tapestry5.corelib.components.Loop$3.execute(Loop.java:96)
>> at 
>> org.apache.tapestry5.corelib.components.Form.executeStoredActions(Form.java:471)
>> ... 81 more
>>
>
> -
> To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
> For additional commands, e-mail: users-h...@tapestry.apache.org
>
>



-- 
Howard M. Lewis Ship

Creator Apache Tapestry and Apache HiveMind

-
To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
For additional commands, e-mail: users-h...@tapestry.apache.org



Re: [T5.1.0.0] Loop in Form problem introduced in T5.1.0.0

2009-03-12 Thread Joost Schouten (mailing lists)
Hi,

AjaxFormLoop seems intended for formitems and would require a lot of
javascript wiring to make it do what I want it to do. All I need is
for the Form to completely ignore the Loop, just like it did nicely in
5.0.18. Do you know why the Loop's state needs to be persisted in the
first place? And why can I not tell it to be completely ignored by the
Form?

It seems to me that all this state saving on a loop is needed if there
are formitems in the loop. If so, it'd be great if I could just ignore
the whole state saving and use the Loop in a nice and simple way by
setting something like ignoreForm=true.

Cheers,
Joost

On Tue, Mar 10, 2009 at 1:29 PM, DH  wrote:
> Hi,
>
> In your case, why not have a try on AjaxFormLoop component, but I haven't 
> tried this component yet and don't have much experience.
>
> Loop component in form is a bit tricky. Set volatile='true' means you need 
> have your source object unchanged. But you have deleted one row during 
> process, so exception happens.
>
> Thanks
>
> DH
>
>
> - Original Message -
> From: "Joost Schouten (mailing lists)" 
> To: "Tapestry users" 
> Sent: Tuesday, March 10, 2009 11:13 AM
> Subject: Re: [T5.1.0.0] Loop in Form problem introduced in T5.1.0.0
>
>
> Dear DH,
>
> Thanks for you quick response. I added the param but now get a new
> Exception (see below). The exception still only happens when elements
> are removed from the Loop through AJAX, adding all works fine. This
> whole volatile concept is a bit fuzzy to me and scanning the source of
> the Loop component does not clear things up to me. Do you have any
> further pointers?
>
> Cheers,
> Joost
>
> --- the new Exception --
>
> Caused by: java.util.NoSuchElementException
> at java.util.AbstractList$Itr.next(AbstractList.java:427)
> at org.apache.tapestry5.corelib.components.Loop.advanceVolatile(Loop.java:335)
> at org.apache.tapestry5.corelib.components.Loop.access$200(Loop.java:41)
> at org.apache.tapestry5.corelib.components.Loop$3.execute(Loop.java:92)
> at org.apache.tapestry5.corelib.components.Loop$3.execute(Loop.java:96)
> at 
> org.apache.tapestry5.corelib.components.Form.executeStoredActions(Form.java:471)
> ... 81 more
>

-
To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
For additional commands, e-mail: users-h...@tapestry.apache.org



Re: [T5.1.0.0] Loop in Form problem introduced in T5.1.0.0

2009-03-09 Thread DH
Hi, 

In your case, why not have a try on AjaxFormLoop component, but I haven't tried 
this component yet and don't have much experience.

Loop component in form is a bit tricky. Set volatile='true' means you need have 
your source object unchanged. But you have deleted one row during process, so 
exception happens.

Thanks

DH


- Original Message - 
From: "Joost Schouten (mailing lists)" 
To: "Tapestry users" 
Sent: Tuesday, March 10, 2009 11:13 AM
Subject: Re: [T5.1.0.0] Loop in Form problem introduced in T5.1.0.0


Dear DH,

Thanks for you quick response. I added the param but now get a new
Exception (see below). The exception still only happens when elements
are removed from the Loop through AJAX, adding all works fine. This
whole volatile concept is a bit fuzzy to me and scanning the source of
the Loop component does not clear things up to me. Do you have any
further pointers?

Cheers,
Joost

--- the new Exception --

Caused by: java.util.NoSuchElementException
at java.util.AbstractList$Itr.next(AbstractList.java:427)
at org.apache.tapestry5.corelib.components.Loop.advanceVolatile(Loop.java:335)
at org.apache.tapestry5.corelib.components.Loop.access$200(Loop.java:41)
at org.apache.tapestry5.corelib.components.Loop$3.execute(Loop.java:92)
at org.apache.tapestry5.corelib.components.Loop$3.execute(Loop.java:96)
at 
org.apache.tapestry5.corelib.components.Form.executeStoredActions(Form.java:471)
... 81 more


Re: [T5.1.0.0] Loop in Form problem introduced in T5.1.0.0

2009-03-09 Thread Joost Schouten (mailing lists)
Dear DH,

Thanks for you quick response. I added the param but now get a new
Exception (see below). The exception still only happens when elements
are removed from the Loop through AJAX, adding all works fine. This
whole volatile concept is a bit fuzzy to me and scanning the source of
the Loop component does not clear things up to me. Do you have any
further pointers?

Cheers,
Joost

--- the new Exception --

Caused by: java.util.NoSuchElementException
at java.util.AbstractList$Itr.next(AbstractList.java:427)
at 
org.apache.tapestry5.corelib.components.Loop.advanceVolatile(Loop.java:335)
at org.apache.tapestry5.corelib.components.Loop.access$200(Loop.java:41)
at org.apache.tapestry5.corelib.components.Loop$3.execute(Loop.java:92)
at org.apache.tapestry5.corelib.components.Loop$3.execute(Loop.java:96)
at 
org.apache.tapestry5.corelib.components.Form.executeStoredActions(Form.java:471)
... 81 more

On Mon, Mar 9, 2009 at 9:03 PM, ningdh  wrote:
> Set volatile="true" at the loop component to let the form not to restore the 
> state.
>
> Thanks,
> DH
>
> - Original Message -
> From: "Joost Schouten (mailing lists)" 
> To: "Tapestry users" 
> Sent: Monday, March 09, 2009 6:14 PM
> Subject: [T5.1.0.0] Loop in Form problem introduced in T5.1.0.0
>
>
> Hi,
>
> I have a loop in a form displaying non form information. An ajax call
> can update the source of the Loop. When the loop has less, or
> different items in it during submit then when the form was initiated,
> the following exception is thrown.
> Loop.RestoreStateFromStoredClientValue() seems to be causing this
> problem. My question; Why does the form care about restoring state of
> a Loop not containing any FormItems? Second, how can I fix this
> problem? I cannot pull my loop out of the form unfortunately.
>
> This seems to be a new problem introduced in 5.1.0.0 as in version
> 5.0.18 all works fine.
>
> Cheers,
> Joost
>
> -- debug and stack trace ---
>
> DEBUG 09 Mar 2009 17:29:14,186 [qtp0-3]
> org.apache.tapestry5.ioc.internal.services.MethodLogger.entry(MethodLogger.java:73)
> - [ENTER] onAction(org.apache.tapestry5.internal.emptyeventcont...@422f73)
> DEBUG 09 Mar 2009 17:29:14,187 [qtp0-3]
> org.apache.tapestry5.corelib.components.Form.executeStoredActions(Form.java:458)
> - Processing actions:
> H4sIAM2TP2gUQRTGx0Bs0ohg6i1ikSJzieQ0nohZLptwctk7bs/IISizs2/3Ns7OrDOzJodgY6GFvZ0g2vmntTeFpLFR7AMiNoIoWin4chdRESRBCVftzLxv3/d7s98+ek9G1y6QjgFeaIhKhQFdWmCmGyqmo0rOEhCspwpLf1kKlSQQGctsYUKh+GVq1lLLuwYEcKs0ajVIa4RSudGEKp1QljPeBWpZDsbqXplypUGkIT6zXMltOa2jfqI81dh8PUmubY4Qsp4PF9tM583jT/HTl/f2hc3fE1sL61gKsDssapUF27uoKlKUrDBRwNSdZ69uEefbCDlQJ2P8Z8GSw/VVdpWVBJNJKbA6lcmp9dySm+hBV5Uy1vAuDgCShoVJJRjDoiyVNFMRCFpFEiZ788fieO7EScd3l72KczZwmkpbJpwFL6i2as12reFXHFkI4bQ7TVRUG8tN1+9capz3vZYTtN02HrrVdm3FS3E0fFdycCrOzPRwhWD2Yx5PLo0/PDOEAT0+fejD3MUHt08P2GIS/V82xrkq0K2/T5U0wDSWNSn/FTNkBqgb4iHjdjEFEU0EYIv86LmNsa0jz7/uRFJJq5XwWQZXyHUyuh3B8R3H4Idj0Hfcx8ncvU7W1IrjHxIUYZYag602nkSz8Ze7LwbfZIl4/0reZ0S0+d1mo89i/yR7u9X6fMO7/25w/9g2Q/lv939wYPYdYIg+ficGAAA=
> DEBUG 09 Mar 2009 17:29:14,190 [qtp0-3]
> org.apache.tapestry5.corelib.components.Form.executeStoredActions(Form.java:475)
> - Processing: 
> secured/user/Dashboard:pagelayout.pagelayout.loggedstatusblock.switchselector.parentsloop
> Loop.PrepareForSubmission
> DEBUG 09 Mar 2009 17:29:14,191 [qtp0-3]
> org.apache.tapestry5.corelib.components.Form.executeStoredActions(Form.java:475)
> - Processing: 
> secured/user/Dashboard:pagelayout.pagelayout.loggedstatusblock.switchselector.parentsloop
> Loop.ResetIndex
> DEBUG 09 Mar 2009 17:29:14,193 [qtp0-3]
> org.apache.tapestry5.corelib.components.Form.executeStoredActions(Form.java:475)
> - Processing: 
> secured/user/Dashboard:pagelayout.pagelayout.loggedstatusblock.switchselector.parentsloop
> loop.restorestatefromstoredclientvalue[com.joostschouten.businessadmin.model.comp...@2ff879
> NAME: JS Portal DESCRIPTION: null TYPE: COMPANY_OWNER STATE:
> ACTIVEimportance : 10]
> DEBUG 09 Mar 2009 17:29:14,200 [qtp0-3]
> org.apache.tapestry5.ioc.internal.ConstructorServiceCreator.createObject(ConstructorServiceCreator.java:60)
> - Invoking constructor
> org.apache.tapestry5.ioc.internal.services.ExceptionTrackerImpl() (at
> ExceptionTrackerImpl.java:25) via
> org.apache.tapestry5.ioc.services.TapestryIOCModule.bind(ServiceBinder)
> (at TapestryIOCModule.java:41).
> DEBUG 09 Mar 2009 17:29:14,201 [qtp0-3]
> org.apache.tapestry5.ioc.internal.services.MethodLogger.fail(MethodLogger.java:164)
> - [ FAIL] onAction --
> org.apache.tapestry5.ioc.internal.util.TapestryException
> org.apache.tapestry5.ioc.internal.util.TapestryException: Could not
> find a coercion from type java.lang.S

Re: [T5.1.0.0] Loop in Form problem introduced in T5.1.0.0

2009-03-09 Thread ningdh
Set volatile="true" at the loop component to let the form not to restore the 
state.

Thanks,
DH

- Original Message - 
From: "Joost Schouten (mailing lists)" 
To: "Tapestry users" 
Sent: Monday, March 09, 2009 6:14 PM
Subject: [T5.1.0.0] Loop in Form problem introduced in T5.1.0.0


Hi,

I have a loop in a form displaying non form information. An ajax call
can update the source of the Loop. When the loop has less, or
different items in it during submit then when the form was initiated,
the following exception is thrown.
Loop.RestoreStateFromStoredClientValue() seems to be causing this
problem. My question; Why does the form care about restoring state of
a Loop not containing any FormItems? Second, how can I fix this
problem? I cannot pull my loop out of the form unfortunately.

This seems to be a new problem introduced in 5.1.0.0 as in version
5.0.18 all works fine.

Cheers,
Joost

-- debug and stack trace ---

DEBUG 09 Mar 2009 17:29:14,186 [qtp0-3]
org.apache.tapestry5.ioc.internal.services.MethodLogger.entry(MethodLogger.java:73)
- [ENTER] onAction(org.apache.tapestry5.internal.emptyeventcont...@422f73)
DEBUG 09 Mar 2009 17:29:14,187 [qtp0-3]
org.apache.tapestry5.corelib.components.Form.executeStoredActions(Form.java:458)
- Processing actions:
H4sIAM2TP2gUQRTGx0Bs0ohg6i1ikSJzieQ0nohZLptwctk7bs/IISizs2/3Ns7OrDOzJodgY6GFvZ0g2vmntTeFpLFR7AMiNoIoWin4chdRESRBCVftzLxv3/d7s98+ek9G1y6QjgFeaIhKhQFdWmCmGyqmo0rOEhCspwpLf1kKlSQQGctsYUKh+GVq1lLLuwYEcKs0ajVIa4RSudGEKp1QljPeBWpZDsbqXplypUGkIT6zXMltOa2jfqI81dh8PUmubY4Qsp4PF9tM583jT/HTl/f2hc3fE1sL61gKsDssapUF27uoKlKUrDBRwNSdZ69uEefbCDlQJ2P8Z8GSw/VVdpWVBJNJKbA6lcmp9dySm+hBV5Uy1vAuDgCShoVJJRjDoiyVNFMRCFpFEiZ788fieO7EScd3l72KczZwmkpbJpwFL6i2as12reFXHFkI4bQ7TVRUG8tN1+9capz3vZYTtN02HrrVdm3FS3E0fFdycCrOzPRwhWD2Yx5PLo0/PDOEAT0+fejD3MUHt08P2GIS/V82xrkq0K2/T5U0wDSWNSn/FTNkBqgb4iHjdjEFEU0EYIv86LmNsa0jz7/uRFJJq5XwWQZXyHUyuh3B8R3H4Idj0Hfcx8ncvU7W1IrjHxIUYZYag602nkSz8Ze7LwbfZIl4/0reZ0S0+d1mo89i/yR7u9X6fMO7/25w/9g2Q/lv939wYPYdYIg+ficGAAA=
DEBUG 09 Mar 2009 17:29:14,190 [qtp0-3]
org.apache.tapestry5.corelib.components.Form.executeStoredActions(Form.java:475)
- Processing: 
secured/user/Dashboard:pagelayout.pagelayout.loggedstatusblock.switchselector.parentsloop
Loop.PrepareForSubmission
DEBUG 09 Mar 2009 17:29:14,191 [qtp0-3]
org.apache.tapestry5.corelib.components.Form.executeStoredActions(Form.java:475)
- Processing: 
secured/user/Dashboard:pagelayout.pagelayout.loggedstatusblock.switchselector.parentsloop
Loop.ResetIndex
DEBUG 09 Mar 2009 17:29:14,193 [qtp0-3]
org.apache.tapestry5.corelib.components.Form.executeStoredActions(Form.java:475)
- Processing: 
secured/user/Dashboard:pagelayout.pagelayout.loggedstatusblock.switchselector.parentsloop
loop.restorestatefromstoredclientvalue[com.joostschouten.businessadmin.model.comp...@2ff879
NAME: JS Portal DESCRIPTION: null TYPE: COMPANY_OWNER STATE:
ACTIVEimportance : 10]
DEBUG 09 Mar 2009 17:29:14,200 [qtp0-3]
org.apache.tapestry5.ioc.internal.ConstructorServiceCreator.createObject(ConstructorServiceCreator.java:60)
- Invoking constructor
org.apache.tapestry5.ioc.internal.services.ExceptionTrackerImpl() (at
ExceptionTrackerImpl.java:25) via
org.apache.tapestry5.ioc.services.TapestryIOCModule.bind(ServiceBinder)
(at TapestryIOCModule.java:41).
DEBUG 09 Mar 2009 17:29:14,201 [qtp0-3]
org.apache.tapestry5.ioc.internal.services.MethodLogger.fail(MethodLogger.java:164)
- [ FAIL] onAction --
org.apache.tapestry5.ioc.internal.util.TapestryException
org.apache.tapestry5.ioc.internal.util.TapestryException: Could not
find a coercion from type java.lang.String to type
com.joostschouten.businessadmin.model.Account.
at 
org.apache.tapestry5.corelib.components.Form.executeStoredActions(Form.java:492)
at 
org.apache.tapestry5.corelib.components.Form._$advised$onAction(Form.java:375)
at 
org.apache.tapestry5.corelib.components.Form$onAction$invocation_11fea8e560c.invokeAdvisedMethod(Form$onAction$invocation_11fea8e560c.java)
at 
org.apache.tapestry5.internal.services.AbstractComponentMethodInvocation.proceed(AbstractComponentMethodInvocation.java:71)
at 
org.apache.tapestry5.ioc.internal.services.LoggingAdvice.advise(LoggingAdvice.java:45)
at org.apache.tapestry5.internal.transform.LogWorker$1.advise(LogWorker.java:54)
at 
org.apache.tapestry5.internal.services.AbstractComponentMethodInvocation.proceed(AbstractComponentMethodInvocation.java:80)
at org.apache.tapestry5.corelib.components.Form.onAction(Form.java)
at 
org.apache.tapestry5.corelib.components.Form.dispatchComponentEvent(Form.java)
at 
org.apache.tapestry5.internal.structure.ComponentPageElementImpl.dispatchEvent(ComponentPageElementImpl.java:910)
at 
org.apache.tapestry5.internal.structure.ComponentPageElementImpl.triggerContextEvent(ComponentPageElementImpl.java:1081)
at 
org.apache.tapestry5.internal.services.ComponentEventRequestHandlerImpl.handle(ComponentEventRequestHandlerImpl.jav

[T5.1.0.0] Loop in Form problem introduced in T5.1.0.0

2009-03-09 Thread Joost Schouten (mailing lists)
Hi,

I have a loop in a form displaying non form information. An ajax call
can update the source of the Loop. When the loop has less, or
different items in it during submit then when the form was initiated,
the following exception is thrown.
Loop.RestoreStateFromStoredClientValue() seems to be causing this
problem. My question; Why does the form care about restoring state of
a Loop not containing any FormItems? Second, how can I fix this
problem? I cannot pull my loop out of the form unfortunately.

This seems to be a new problem introduced in 5.1.0.0 as in version
5.0.18 all works fine.

Cheers,
Joost

-- debug and stack trace ---

DEBUG 09 Mar 2009 17:29:14,186 [qtp0-3]
org.apache.tapestry5.ioc.internal.services.MethodLogger.entry(MethodLogger.java:73)
- [ENTER] onAction(org.apache.tapestry5.internal.emptyeventcont...@422f73)
DEBUG 09 Mar 2009 17:29:14,187 [qtp0-3]
org.apache.tapestry5.corelib.components.Form.executeStoredActions(Form.java:458)
- Processing actions:
H4sIAM2TP2gUQRTGx0Bs0ohg6i1ikSJzieQ0nohZLptwctk7bs/IISizs2/3Ns7OrDOzJodgY6GFvZ0g2vmntTeFpLFR7AMiNoIoWin4chdRESRBCVftzLxv3/d7s98+ek9G1y6QjgFeaIhKhQFdWmCmGyqmo0rOEhCspwpLf1kKlSQQGctsYUKh+GVq1lLLuwYEcKs0ajVIa4RSudGEKp1QljPeBWpZDsbqXplypUGkIT6zXMltOa2jfqI81dh8PUmubY4Qsp4PF9tM583jT/HTl/f2hc3fE1sL61gKsDssapUF27uoKlKUrDBRwNSdZ69uEefbCDlQJ2P8Z8GSw/VVdpWVBJNJKbA6lcmp9dySm+hBV5Uy1vAuDgCShoVJJRjDoiyVNFMRCFpFEiZ788fieO7EScd3l72KczZwmkpbJpwFL6i2as12reFXHFkI4bQ7TVRUG8tN1+9capz3vZYTtN02HrrVdm3FS3E0fFdycCrOzPRwhWD2Yx5PLo0/PDOEAT0+fejD3MUHt08P2GIS/V82xrkq0K2/T5U0wDSWNSn/FTNkBqgb4iHjdjEFEU0EYIv86LmNsa0jz7/uRFJJq5XwWQZXyHUyuh3B8R3H4Idj0Hfcx8ncvU7W1IrjHxIUYZYag602nkSz8Ze7LwbfZIl4/0reZ0S0+d1mo89i/yR7u9X6fMO7/25w/9g2Q/lv939wYPYdYIg+ficGAAA=
DEBUG 09 Mar 2009 17:29:14,190 [qtp0-3]
org.apache.tapestry5.corelib.components.Form.executeStoredActions(Form.java:475)
- Processing: 
secured/user/Dashboard:pagelayout.pagelayout.loggedstatusblock.switchselector.parentsloop
Loop.PrepareForSubmission
DEBUG 09 Mar 2009 17:29:14,191 [qtp0-3]
org.apache.tapestry5.corelib.components.Form.executeStoredActions(Form.java:475)
- Processing: 
secured/user/Dashboard:pagelayout.pagelayout.loggedstatusblock.switchselector.parentsloop
Loop.ResetIndex
DEBUG 09 Mar 2009 17:29:14,193 [qtp0-3]
org.apache.tapestry5.corelib.components.Form.executeStoredActions(Form.java:475)
- Processing: 
secured/user/Dashboard:pagelayout.pagelayout.loggedstatusblock.switchselector.parentsloop
loop.restorestatefromstoredclientvalue[com.joostschouten.businessadmin.model.comp...@2ff879
NAME: JS Portal DESCRIPTION: null TYPE: COMPANY_OWNER STATE:
ACTIVEimportance : 10]
DEBUG 09 Mar 2009 17:29:14,200 [qtp0-3]
org.apache.tapestry5.ioc.internal.ConstructorServiceCreator.createObject(ConstructorServiceCreator.java:60)
- Invoking constructor
org.apache.tapestry5.ioc.internal.services.ExceptionTrackerImpl() (at
ExceptionTrackerImpl.java:25) via
org.apache.tapestry5.ioc.services.TapestryIOCModule.bind(ServiceBinder)
(at TapestryIOCModule.java:41).
DEBUG 09 Mar 2009 17:29:14,201 [qtp0-3]
org.apache.tapestry5.ioc.internal.services.MethodLogger.fail(MethodLogger.java:164)
- [ FAIL] onAction --
org.apache.tapestry5.ioc.internal.util.TapestryException
org.apache.tapestry5.ioc.internal.util.TapestryException: Could not
find a coercion from type java.lang.String to type
com.joostschouten.businessadmin.model.Account.
at 
org.apache.tapestry5.corelib.components.Form.executeStoredActions(Form.java:492)
at 
org.apache.tapestry5.corelib.components.Form._$advised$onAction(Form.java:375)
at 
org.apache.tapestry5.corelib.components.Form$onAction$invocation_11fea8e560c.invokeAdvisedMethod(Form$onAction$invocation_11fea8e560c.java)
at 
org.apache.tapestry5.internal.services.AbstractComponentMethodInvocation.proceed(AbstractComponentMethodInvocation.java:71)
at 
org.apache.tapestry5.ioc.internal.services.LoggingAdvice.advise(LoggingAdvice.java:45)
at 
org.apache.tapestry5.internal.transform.LogWorker$1.advise(LogWorker.java:54)
at 
org.apache.tapestry5.internal.services.AbstractComponentMethodInvocation.proceed(AbstractComponentMethodInvocation.java:80)
at org.apache.tapestry5.corelib.components.Form.onAction(Form.java)
at 
org.apache.tapestry5.corelib.components.Form.dispatchComponentEvent(Form.java)
at 
org.apache.tapestry5.internal.structure.ComponentPageElementImpl.dispatchEvent(ComponentPageElementImpl.java:910)
at 
org.apache.tapestry5.internal.structure.ComponentPageElementImpl.triggerContextEvent(ComponentPageElementImpl.java:1081)
at 
org.apache.tapestry5.internal.services.ComponentEventRequestHandlerImpl.handle(ComponentEventRequestHandlerImpl.java:75)
at 
org.apache.tapestry5.internal.services.ImmediateActionRenderResponseFilter.handle(ImmediateActionRenderResponseFilter.java:42)
at 
$ComponentEventRequestHandler_11fea8df99b.handle($ComponentEventRequestHandler_11fea8df99b.java)
at 
org.apa