Thoughts on comments package
Lance Weber <lance-kMc2rFPYsS/[email protected]>
| Newsgroups | gmane.comp.web.pyblosxom.user |
|---|---|
| Message-ID | <[email protected]> |
After looking at the comments package (its more than just a plugin!), I can see why it has a reputation for difficult installs. Clearly, adding additional functionality like this is an edge case with pyblosxom - figuring out why is good food for thought. In the long run, I don't think that extending pyblosxom by adding more and more cgi scripts is the right "best practice" for this type of application from a dev/test standpoint. Additionally, as an end user, I want as little web server configuration on my plate as possible. _and_ I want the ability to easily use aliasing/rewriting to control how my url's look. The pyblosxom.cgi should be able to do what little is needed/required before passing on the data to the pyblosxom engine, no matter what functionality is being invoked. This also requires that the pyblosxom engine be "command" driven, and that plugins should have the ability to implement a command method that can listen and respond to specific commands. The current engine implements an implied "view" command. An xmlrpc plugin might implement several new commands that conform to the various xmlrpc blogging standards. A feedbacks plugin would support the various pingback/trackback/comments commands. As Atom continues to cook along, I could definitely see an atom plugin implementing atom commands. So, I'd suggest that pyblosxom support a new url pattern along the lines of a straightforward "$base_url/<command>/<parm>" structure. In order to maintain backwards compatibility, view would be the default command, so that a url missing the <command> structure would have the <parm> section sent to the default view code. However, this opens the possibility for naming collisions: does "$base_url/xmlrpc/test" refer to an xmlrpc command or my xmprpc blog topic? I'd suggest a naming convention that requires commands to begin with an underscore so that "$base_url/_xmlrpc/test" refers to a command while "$base_url/xmlrpc/test" refers to a topic. This would also make the command parse a lot easier/faster too. It looks (to my inexperienced eye) that Pyblosxom.run() could handle this pretty easily, especially given its usage of the callback patterns already. Thoughts? Thanks for being patient with me as I get up to speed... --L ------------------------------------------------------- SF.Net is sponsored by: Speed Start Your Linux Apps Now. Build and deploy apps & Web services for Linux with a free DVD software kit from IBM. Click Now! http://ads.osdn.com/?ad_id=1356&alloc_id=3438&op=click