Re: svn commit: r385992 - in /httpd/mod_python/trunk: lib/python/mod_python/__init__.py src/include/mpversion.h src/mod_python.c

2006-03-15 Thread André Malo
* [EMAIL PROTECTED] wrote:

   **
   *handler function for mod_include tag
 + *
 + *The mod_include tag handler interface changed somewhere
 + *between Apache 2.0 and Apache 2.2. Not sure what the
 + *official way of detecting change point is, so look for
 + *the SSI_CREATE_ERROR_BUCKET macro as indication that
 + *new interface should be used. Provide a completely
 + *separate implementation for now until determine whether
 + *the SSI_CREATE_ERROR_BUCKET macro can be replicated for
 + *backward compatibility.
   */

mod_include was completely refactored for 2.2 and changed its external API
(and ABI) during this step. The reason was, that the API before exposed too
many internal details, which made silent refactoring impossible. At this
point it was changed to fix these mistakes and go on with the refactoring :)

Anyway. The official way to determine such changes is the module magic number
in ap_mmn.h. There's a major MMN and a minor MMN. The major MMN bumps for
backward incompatiblity and the minor number for forward compatibility
(e.g. new functions).

And there you'll find:

 * 20030821 (2.1.0-dev) bumped mod_include's entire API

You can use the macros in ap_mmn.h to determine the version of the code.

nd


Re: Vote on whether to integrate server side include (SSI) support.

2006-03-14 Thread André Malo
* Graham Dumpleton [EMAIL PROTECTED] wrote:

  Do you have examples of SSI tag handlers that you might implement this
  way if such a feature were available? I ask as it all good to speculate
  on such a feature, but like this generic #python tag, would it in
  itself be used either?

Actually, I'd hardly use the the #python tag by itself, but specific
functions, provided by my application as needed (like the SSI templates
are provided by my application but designed by someone else!).

 All you thus get by having an explicit registered tag is that that 
 Python
 is used can be hidden and a user would be none the wiser.

Exactly that's the point. Separation of concerns - I'm not a friend of a
raw programming language in a template.
Therefore - if you really want to pass httpd features to mod_python, it
would be nice to consider this one :)

nd


Re: Vote on whether to integrate server side include (SSI) support.

2006-03-12 Thread André Malo
* Graham Dumpleton wrote:

 Not seeing any negatives, I am going to go ahead and commit the SSI
 stuff. Comments that this is just another way to skin a cat are true,
 even if a small cat.  I guess the reason for doing it is to fill out
 those basic features that can be filled out by using just what Apache
 provides.

If that's a point, you know, what would be really great in this case? To be 
able to register own SSI handlers using mod_python instead of (or in 
addition to) this generic #python thingy, which nobody really seems to be 
able to classify/justify. Like registering a name and a callback function 
with a fixed signature.

What do you think?

nd
-- 
die (eval q-qq:Just Another Perl Hacker
:-)

# André Malo, http://www.perlig.de/ #