Michael Barton (JIRA | 25 Oct 10:42
Favicon
Gravatar

Commented: (MODPYTHON-222) Support for chunked transfer encoding on request content.


    [
https://issues.apache.org/jira/browse/MODPYTHON-222?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12642604#action_12642604
] 

Michael Barton commented on MODPYTHON-222:
------------------------------------------

I'd love to see this issue fixed in some manner.  Chunked transfer would be useful for stuff like streaming
the output of gzip to the server rather than spooling to disk locally to get the length first.

I don't know enough about mod_python to properly evaluate the above patch, but it's been working for me.

> Support for chunked transfer encoding on request content.
> ---------------------------------------------------------
>
>                 Key: MODPYTHON-222
>                 URL: https://issues.apache.org/jira/browse/MODPYTHON-222
>             Project: mod_python
>          Issue Type: New Feature
>          Components: core
>    Affects Versions: 3.3.1
>            Reporter: Graham Dumpleton
>         Attachments: mod_python-211-212-222-fix-revised.patch, requestobject.c
>
>
> It is currently not possible to use chunked transfer encoding on request content delivered to a
mod_python request handler.
> The use of chunked transfer encoding is explicitly blocked in C code by:
>         rc = ap_setup_client_block(self->request_rec, REQUEST_CHUNKED_ERROR);
(Continue reading)

Favicon
Gravatar

Created: (MODPYTHON-252) mod_python install forces Python libraries into system-wide install directory

mod_python install forces Python libraries into system-wide install directory
-----------------------------------------------------------------------------

                 Key: MODPYTHON-252
                 URL: https://issues.apache.org/jira/browse/MODPYTHON-252
             Project: mod_python
          Issue Type: Bug
          Components: core
    Affects Versions: 3.3.1
         Environment: Tested on Linux, with mod_python 3.3.1
            Reporter: Josh Kupershmidt
            Priority: Minor
             Fix For: 3.3.1

I need to have mod_python installed as an unprivileged user. I have Apache installed as an unprivileged
user, to directory

/home/user/apache/2.0.63/... 

And I need mod_python.so installed to 

/home/user/apache/2.0.63/modules

The arguments I pass to ./configure are:

./configure --with-apache=/home/user/apache/2.0.63/
--prefix=/home/user/apache/2.0.63/modules/
--with-python=/directory/to/system-wide/install/of/python --with-apxs=/home/user/apache/2.0.63/bin

This all works fine for installing mod_python.so into Apache's modules directory. However, the Python
(Continue reading)

Favicon
Gravatar

Assigned: (MODPYTHON-238) req.connection.keepalive should be writable


     [
https://issues.apache.org/jira/browse/MODPYTHON-238?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Graham Dumpleton reassigned MODPYTHON-238:
------------------------------------------

    Assignee: Graham Dumpleton

> req.connection.keepalive should be writable
> -------------------------------------------
>
>                 Key: MODPYTHON-238
>                 URL: https://issues.apache.org/jira/browse/MODPYTHON-238
>             Project: mod_python
>          Issue Type: Improvement
>          Components: core
>    Affects Versions: 3.3.1
>            Reporter: Graham Dumpleton
>            Assignee: Graham Dumpleton
>            Priority: Minor
>             Fix For: 3.3.x
>
>
> The attribute req.connection.keepalive should be writable. This would allow handlers to use:
>   req.connection.keepalive = apache.AP_CONN_CLOSE
> Doing this before any data is written has the effect of disabling keepalive and also turning off chunked
encoding for response content when no content length has been supplied.

(Continue reading)

Favicon
Gravatar

Updated: (MODPYTHON-238) req.connection.keepalive should be writable


     [
https://issues.apache.org/jira/browse/MODPYTHON-238?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Graham Dumpleton updated MODPYTHON-238:
---------------------------------------

    Fix Version/s: 3.3.x

Fixed in revision 687024 of trunk.

> req.connection.keepalive should be writable
> -------------------------------------------
>
>                 Key: MODPYTHON-238
>                 URL: https://issues.apache.org/jira/browse/MODPYTHON-238
>             Project: mod_python
>          Issue Type: Improvement
>          Components: core
>    Affects Versions: 3.3.1
>            Reporter: Graham Dumpleton
>            Priority: Minor
>             Fix For: 3.3.x
>
>
> The attribute req.connection.keepalive should be writable. This would allow handlers to use:
>   req.connection.keepalive = apache.AP_CONN_CLOSE
> Doing this before any data is written has the effect of disabling keepalive and also turning off chunked
encoding for response content when no content length has been supplied.

(Continue reading)

Jason Carver (JIRA | 7 Aug 01:55
Favicon
Gravatar

Created: (MODPYTHON-251) Protect against calls to deleted req object

Protect against calls to deleted req object
-------------------------------------------

                 Key: MODPYTHON-251
                 URL: https://issues.apache.org/jira/browse/MODPYTHON-251
             Project: mod_python
          Issue Type: Improvement
          Components: core
    Affects Versions: 3.3.1
         Environment: Replicated on:
Windows XP SP3, using Apache 2.2, Python 2.5.2
Ubuntu 7.10, using Apache 2.2, Python 2.5.2
            Reporter: Jason Carver

When the logging module is passed the Apache req object as a handler, and the req object is never removed,
subsequent calls to logging crash mod_python and Apache.  I expected the page to display a Traceback instead.

This code demonstrates the crash:

def testCrash(req):
    """
    Reliably crash server (on 2nd page access)
    Open as: http://server/index.py/testCrash
    """
    handler = logging.StreamHandler(req)
    logging.getLogger('').addHandler( handler )
    logging.exception('I crash')

    #removing this line will cause an apache crash on the
    #    second web page access
(Continue reading)

Vincent Legoll (JIRA | 12 Feb 11:08
Favicon
Gravatar

Created: (MODPYTHON-247) glitches in CGI handler documentation

glitches in CGI handler documentation
-------------------------------------

                 Key: MODPYTHON-247
                 URL: https://issues.apache.org/jira/browse/MODPYTHON-247
             Project: mod_python
          Issue Type: Bug
          Components: documentation
    Affects Versions: 3.3.1
         Environment: NA
            Reporter: Vincent Legoll
            Priority: Trivial

I found small glitches in the doc for CGI handler

Colin Fox (JIRA | 30 Jan 02:04
Favicon
Gravatar

Created: (MODPYTHON-246) The apache return codes should either be moved to the apache section.

The apache return codes should either be moved to the apache section.
---------------------------------------------------------------------

                 Key: MODPYTHON-246
                 URL: https://issues.apache.org/jira/browse/MODPYTHON-246
             Project: mod_python
          Issue Type: Improvement
          Components: documentation
    Affects Versions: 3.3.1
            Reporter: Colin Fox

Currently, the apache section of the documentation (4.5) doesn't mention the apache return codes. These
are documented in section 4.2, but there is nothing in section 4.5 mentioning this.

As someone coming to the documentation after a long hiatus, this was a little frustrating to me. I
accidentally stumbled across section 4.2.

The index should also mention error codes or return codes or something.

Favicon
Gravatar

Created: (MODPYTHON-245) Incorrect prototype for exported optional function.

Incorrect prototype for exported optional function.
---------------------------------------------------

                 Key: MODPYTHON-245
                 URL: https://issues.apache.org/jira/browse/MODPYTHON-245
             Project: mod_python
          Issue Type: Bug
          Components: core
    Affects Versions: 3.3.1
            Reporter: Graham Dumpleton
            Priority: Minor

The optional function prototype in src/include/mod_python.h.in is listed as:

APR_DECLARE_OPTIONAL_FN(void *, mp_release_interpreter, ());

it should be:

APR_DECLARE_OPTIONAL_FN(void, mp_release_interpreter, ());

Code will not compile on some very pedantic compilers.

826    APR_REGISTER_OPTIONAL_FN(mp_release_interpreter);
826    do { apr_OFN_mp_release_interpreter_t *apu__opt = mp_release_interpreter;
apr_dynamic_fn_register("mp_release_interpreter",(apr_opt_fn_t *)apu__opt); } while (0);
Initialization between types "void*(*)()" and "void(*)(void)" is not allowed.

w s (JIRA | 28 Jan 16:38
Favicon
Gravatar

Created: (MODPYTHON-244) Add mention of "req.form" attribute to documentation

Add mention of "req.form" attribute to documentation
----------------------------------------------------

                 Key: MODPYTHON-244
                 URL: https://issues.apache.org/jira/browse/MODPYTHON-244
             Project: mod_python
          Issue Type: Improvement
          Components: documentation
         Environment: All environments
            Reporter: w s

I am currently documenting an application built with mod_python (it has been great overall), and I would
like to provide a link for a description of "req.form", since I use it a lot, but its only mentions are in the
FAQ, in email archives, and in some random places like release notes and diffs.

Are those of us who use PublisherHandler in such a small minority that req.form should be a mostly
undocumented feature?

Interestingly the the following Google search  yields nothing in  the main documentation tree, and only 19
hits total:

site:www.modpython.org  "req.form" -pipermail

But allowing for pipermail, we get nearly 300 hits that mention req.form.

I also realize I can download the docs and write a patch.  I probably won't have time, but if this could go in a
TODO or something, it might flatten the learning curve for more users of mod_python later.

Ken Brownfield (JIRA | 23 Jan 23:22
Favicon
Gravatar

Updated: (MODPYTHON-3) mod_python cannot parse cookies with $-prefixed attributes


     [
https://issues.apache.org/jira/browse/MODPYTHON-3?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Ken Brownfield updated MODPYTHON-3:
-----------------------------------

    Attachment: mod_python-3.3.1-kb0.patch.txt

> mod_python cannot parse cookies with $-prefixed attributes
> ----------------------------------------------------------
>
>                 Key: MODPYTHON-3
>                 URL: https://issues.apache.org/jira/browse/MODPYTHON-3
>             Project: mod_python
>          Issue Type: Bug
>    Affects Versions: 3.1.3
>            Reporter: Nicolas Lehuen
>            Assignee: Nicolas Lehuen
>             Fix For: 3.2.7
>
>         Attachments: mod_python-3.3.1-kb0.patch.txt
>
>
> Craig Warren (to mod_python, python-dev)
> I found an error while with Cookie module.  When the cookie module parses a cookie, if that cooke has
$Version or $Path in it you get an error. My cookie is coming from a java libaray, that puts $Version and
$Path in it.
> example ="Cookie: $Version=0; pysid=34a9b38c34;$Path=/"
> RFC 2109 mentions $Version and $Path in Section 4.4
(Continue reading)

Ken Brownfield (JIRA | 23 Jan 23:22
Favicon
Gravatar

Commented: (MODPYTHON-3) mod_python cannot parse cookies with $-prefixed attributes


    [
https://issues.apache.org/jira/browse/MODPYTHON-3?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12561837#action_12561837
] 

Ken Brownfield commented on MODPYTHON-3:
----------------------------------------

We're unable to use mod_python v3.3.1 in production without the patch below.  It's a pretty
self-explanatory precedence issue:

--- Cookie.py   2007/12/15 21:45:42     1.1
+++ Cookie.py   2007/12/15 21:46:06
@@ -344,7 +344,7 @@

         # We just ditch the cookies names which start with a dollar
sign since
         # those are in fact RFC2965 cookies attributes. See bug
[#MODPYTHON-3].
-        if key[0]!='$' and names is None or key in names:
+        if key[0]!='$' and ( names is None or key in names ):
             result[key] = Class(key, val)

     return result

Comments?  This patch has been in heavy production use for a couple of months without incident.

Thanks,
Ken.

(Continue reading)


Gmane