Page 1 of 1

Debugging nocache errors

Posted: Sun Mar 26, 2006 1:15 pm
by pinthenet
Can someone give me some pointers for debugging a module plse?
I created a modified Bookmarks module under release 0.11 to handle Links including images. It worked OK (although I occasionally got unexplainable nocache errors when editing, which disappeared after clearing the cache), but now with 0.12.1 I always get errors as soon as I include the module, even if the module doesn't have anything to output based on the selected filters (category etc)

The nocache errors appear before/after each {} on the page - eg {title}, {style} and of course any other {cms_module...} tags. All error values are the same apart form the sequence nr at the end

Running with debug shows no errors and if I compare with eg News or the new Bookmarks I can't really see any major differences in the template calls etc.

Also, although Preview works (except for the nocache errors), after apply/submit I often have a real page with no template or style until I clear the cache

Any tips appreciated

PS I use external templates - the bookmarks module at the time (1.3 I think) did not support them

John

Re: Debugging nocache errors

Posted: Tue Mar 28, 2006 2:28 pm
by pinthenet
Oh well, in the absence of any tips I've decided to change my tactics and use a tag to format links and do without a module & database support.

Never mind  :-\

Re: Debugging nocache errors

Posted: Tue Mar 28, 2006 5:10 pm
by Ted
Sometimes the output of the error will fall into a tag and the browser won't display it.  It's usually best to look at the html source and see if you can find an error somewhere.  It's almost always down at the bottom of the source.

Re: Debugging nocache errors

Posted: Tue Mar 28, 2006 6:27 pm
by pinthenet
Thanks Ted
having made the change I realise that my module was a bit over the top for what I really needed, so it was a useful exercise anyway.

I'll remember your tip for the next experiment ::). I think I should take the time to study smarty a bit more closely before I try anything elaborate...