Threads of ASP with Python script code

Emile van Sebille emile at fenx.com
Fri Jan 14 07:32:30 EST 2000


It's hard to tell if this will help, but I had a similar situation
where a table of totals doubled each time it was viewed.  When I
modified the table initialization routine to be _very_ explicit,
the problem went away.

HTH

Emile van Sebille
emile at fenx.com
-------------------


Stefan Radke <Stefan_Radke at compuserve.com> wrote in message
news:<387E8361.29684CF9 at compuserve.com>...
> The following ASP gives me trouble:
>
> [HTML]
> [some initialisation script code]
> [more HTML]
> <%
> import my_python_module
> %>
>
> [more HTML, mixed with script code, creating an instance of class in
> my_python_module:]
> this = my_python_module.myClass()
>
> The my_python_module has a class defnition. From this class I create
an
> instance, an read some file names from a disk into a list, the only
member
> of this class. The list is use dto create an options-list on the page.
>
> The problem now is, that whenever I do a reload of the ASP in IE, the
list
> gets longer, because the same files are searched in the
class-initialisation
> again, but the previous instance still exists.
>
> This even does not change, if I add a "del this" at the end. On
another
> machine the same list can be viewed, although a new session has been
> started. To me this means that both ASP sessions use the same memory
space
> within the python environment :-( ...
>
> Does anyone know how to implement this correctly ?  It would mean to
have
> seperate memory in each session.
>
> Thank you for any help, Stefan.
> --
> http://www.python.org/mailman/listinfo/python-list
>







More information about the Python-list mailing list