plainblack.com
Username Password
search
Bookmark and Share
View All Tickets
RSS and Template Engine Error  (#3697)
Issue

We have a client that is  having issue with an RSS feed[1] in WG. One feed is working while another is generating this error in the log. This may reveal an edge-case with RSS feeds. 

--------------------- 

Couldn't call method view on asset for url: morningmonologuerss Root cause: HTML::Template->output() : fatal error in loop output : HTML::Template::param() : attempt to set parameter 'media:content' with an array ref - parameter is not a TMPL_LOOP! at /data/wre/prereqs/perl/lib/site_perl/5.8.8/HTML/Template.pm line 3068

[1] http://morningmonologue.wordpress.com/feed/ 

Diona

----
Knowmad Technologies
http://www.knowmad.com

Solution Summary
Comments
dionak
0
4/8/2008 7:54 pm

Graham has suggested that this is an issue with the way that the feed is passed to the template engine. I'm writing a test for SydicatedContent.pm hoping to discover more detail about the issue. I'll update this bug report if I discover more information.

Diona

----
Knowmad Technologies
http://www.knowmad.com

Graham
0
4/9/2008 9:17 am

The issue here is that one entry in the feed has a single media:content entry, and another has multiple.  These are being passed into the template engine as a scalar, and as an array.  The template engine doesn't like these conflicting types, and dies.  The solution is likely going to be forcing every entry we aren't explicitly handling to be an array.

dionak
0
4/9/2008 3:06 pm

I had hoped to discover this was a version issue and that an upgrade would fix the issue but it sounds as if this is a current bug. Do you think this will be fixed in the next version release? Or could the timeframe for this be extended?

I've attached the beginning of a test. It doesn't yet expose the issue and has the feed in question included in the test. I hope that this test can be expanded and be helpful for debugging.

Thanks,

Diona

----
Knowmad Technologies
http://www.knowmad.com

dionak
0
5/6/2008 8:28 am

Any response on this?

----
Knowmad Technologies
http://www.knowmad.com

topsub
0
5/14/2008 3:22 pm

here is what i believe is a test that exposes the bug.

--

knowmad.com 

preaction
0
6/13/2008 12:34 pm

Dionak: If you want a workaround, try using the Template Toolkit templating language instead. I don't think it has the same limitations as HTML::Template and H::T::Expr (mainly the insane "type" checking).

Let us know how that turns out. I'll look into the problem to see if I can find a sane solution.

preaction
0
6/13/2008 12:49 pm

So it seems <media:content> is an optional field, and optional fields get automatically added to the template parameters, and then if those optional fields do not match what H::T wants, it explodes.

The most correct solution would be to remove everything that we did not explicitly want, with the side-effect that it may limit the usefulness of this asset.

To get around this, we could add a way to include other response tags in the template, so that users would have the ultimate control over it (and any problems that arise would be out of our hands).

preaction
0
6/13/2008 2:32 pm

I've removed all but the necessary fields from the RSS feed. If you want to be able to control which fields get added, while releasing all responsibility from WebGUI for the content of those fields, please submit an RFE for it.

Closing as resolved.

Details
Ticket Status Closed  
Rating0.0 
Submitted Bydionak 
Date Submitted2008-04-07 
Assigned To unassigned  
Date Assigned2019-05-20 
Assigned By 
Severity Fatal (can't continue until this is resolved)  
What's the bug in? WebGUI Stable  
WebGUI / WRE Version 7.3.22-stable  
URLbugs/tracker/rss-and-template-engine-error
Keywords
Related Files
Ticket History
© 2019 Plain Black Corporation | All Rights Reserved