On Mon, 2008-04-28 at 10:57 +0200, Chris Lewis wrote:
> Can you share the full code? What are your activate/passivate methods
> doing? 

For instance this:

 public void onActivate(Long familyId) {
    this.familyIdContext = familyId;
    family = familyDAO.findFamilyWithProducts(familyId);     
 }
    
 public Long onPassivate() {
    return familyIdContext;
 }


> Does that get thrown when the layout is used with a page that has
> no activation context? 

The error gets thrown only on pages that *do* have an activation
context.

> If so, and that really is all to the template
> code, I would say it's a bug. Share more code if you can.

Another thing - although the error gets thrown the application behaves
'normally'.

> 
> chris
> 
> Jan Vissers wrote:
> > Our layout component has:
> >
> > <link rel="shortcut icon" href="favicon.ico"/>
> >
> > If we remove this element - the error disappears. Now this must be a
> > bug, right?
> >
> > -J.
> >
> > On Mon, 2008-04-28 at 10:40 +0200, Jan Vissers wrote:
> >   
> >> Hi,
> >>
> >> In our project we get the following message passivating/activating
> >> pages:
> >>
> >> java.lang.NumberFormatException: For input string: "favicon.ico"
> >>
> >> The more details stack trace shows:
> >>
> >> Caused by: 
> >> java.lang.RuntimeException: Coercion of favicon.ico to type
> >> java.lang.Long (via String --> Long) failed: For input string:
> >> "favicon.ico"
> >>    at
> >> org.apache.tapestry.ioc.internal.services.TypeCoercerImpl.coerce(TypeCoercerImpl.java:130)
> >>    at $TypeCoercer_119942e9313.coerce($TypeCoercer_119942e9313.java)
> >>    at org.apache.tapestry.internal.services.TypeCoercedValueEncoderFactory
> >> $1.toValue(TypeCoercedValueEncoderFactory.java:45)
> >>    at
> >> org.apache.tapestry.internal.services.ContextValueEncoderImpl.toValue(ContextValueEncoderImpl.java:47)
> >>    at
> >> $ContextValueEncoder_119942e9349.toValue($ContextValueEncoder_119942e9349.java)
> >>    at
> >> org.apache.tapestry.internal.URLEventContext.get(URLEventContext.java:43)
> >>    at
> >> org.apache.tapestry.internal.services.ComponentEventImpl.coerceContext(ComponentEventImpl.java:67)
> >>    ... 47 more
> >> Caused by: 
> >> java.lang.NumberFormatException: For input string: "favicon.ico"
> >>    at
> >> java.lang.NumberFormatException.forInputString(NumberFormatException.java:60)
> >>    at java.lang.Long.parseLong(Long.java:415)
> >>    at java.lang.Long.<init>(Long.java:683)
> >>    at org.apache.tapestry.ioc.services.TapestryIOCModule
> >> $7.coerce(TapestryIOCModule.java:159)
> >>    at org.apache.tapestry.ioc.services.TapestryIOCModule
> >> $7.coerce(TapestryIOCModule.java:157)
> >>    at org.apache.tapestry.ioc.services.CoercionTuple
> >> $CoercionWrapper.coerce(CoercionTuple.java:54)
> >>    at
> >> org.apache.tapestry.ioc.internal.services.TypeCoercerImpl.coerce(TypeCoercerImpl.java:126)
> >>    ... 53 more
> >>
> >>
> >> Why is our favicon.ico being tried as a Long coerced value?
> >>
> >> -J.
> >>
> >>
> >> ---------------------------------------------------------------------
> >> To unsubscribe, e-mail: [EMAIL PROTECTED]
> >> For additional commands, e-mail: [EMAIL PROTECTED]
> >>
> >>
> >>     
> >
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > For additional commands, e-mail: [EMAIL PROTECTED]
> >
> >
> >   
> 


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to