You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@velocity.apache.org by Simon Christian <si...@cpd.co.uk> on 2002/07/24 12:18:56 UTC

#parse / #include bug?

I'm not sure if this counts as a bug or not, but certainly results in 
slightly odd behaviour from a designer's perspective: if caching is on 
and you try to #parse a template that has previously been #included (or 
indeed vice versa), a ClassCastException is thrown and the #parse fails.

-----------------------------------------------------
[error] #parse() : arg = include/style.vtl.  Exception : 
java.lang.ClassCastException: 
org.apache.velocity.runtime.resource.ContentResource
-----------------------------------------------------

I can see why this happens, but might there not be a way to cache the 
resources differently possibly by including the resourceType with the 
resourceName when caching/retrieving resources?

- simon


--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


Re: #parse / #include bug?

Posted by "Geir Magnusson Jr." <ge...@adeptra.com>.
On 7/24/02 9:08 AM, "Simon Christian" <si...@cpd.co.uk> wrote:

>> 
>> That's a bug.  Can you put something in bugzilla?
>> 
> 
> ok have done
> 

Thx

-- 
Geir Magnusson Jr. 
Research & Development, Adeptra Inc.
geirm@adeptra.com
+1-203-247-1713



--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


Re: #parse / #include bug?

Posted by Simon Christian <si...@cpd.co.uk>.
> 
> That's a bug.  Can you put something in bugzilla?
> 

ok have done

- simon


--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


Re: #parse / #include bug?

Posted by "Geir Magnusson Jr." <ge...@adeptra.com>.
On 7/24/02 6:18 AM, "Simon Christian" <si...@cpd.co.uk> wrote:

> I'm not sure if this counts as a bug or not, but certainly results in
> slightly odd behaviour from a designer's perspective: if caching is on
> and you try to #parse a template that has previously been #included (or
> indeed vice versa), a ClassCastException is thrown and the #parse fails.
> 
> -----------------------------------------------------
> [error] #parse() : arg = include/style.vtl.  Exception :
> java.lang.ClassCastException:
> org.apache.velocity.runtime.resource.ContentResource
> -----------------------------------------------------
> 
> I can see why this happens, but might there not be a way to cache the
> resources differently possibly by including the resourceType with the
> resourceName when caching/retrieving resources?

That's a bug.  Can you put something in bugzilla?

-- 
Geir Magnusson Jr. 
Research & Development, Adeptra Inc.
geirm@adeptra.com
+1-203-247-1713



--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>