Re: interactions between plugins and static rendering?

will guaraldi <[email protected]>
Newsgroups gmane.comp.web.pyblosxom.user
Message-ID <[email protected]>
On Mon, 20 Nov 2006, Michael Welle wrote:
> 
> correct. But if my understanding of the python code is correct, the 
> run() operation isn't called if pyblosxom.cgi is called with the 
> --static switch.  Only the ctor is invoked and after that the 
> runStaticRenderer() operation is called.

I see the problem.  cb_start and cb_end are called for each url rendered 
in tools.render_url but that happens after cb_filestat is called in 
runStaticRenderer.  So the problem here is likely that hardcodedates needs 
cb_start to be called so that it can set things up and that needs to 
happen before cb_filestat is called.

I think it's correct to say that cb_start should get called before 
cb_filestat, however the current structuring of things doesn't really make 
that easy (if you think it does, please provide a patch).  I'll have to 
think about how to restructure things so that this is fixable in 
PyBlosxom.

However, I claim that this is easily fixable in HardCodeDates by checking 
in cb_filestat to see if the global things are initialized and if they 
aren't, initialize them then.  I don't think it's an ideal fix, but it's a 
good temporary fix until things are fixed in PyBlosxom.

Sorry about that--bad design decisions on my part.

/will

-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys - and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.