Python Mapscript Crashes
Umberto Nicoletti
umberto.nicoletti at GMAIL.COM
Tue Oct 17 01:37:08 PDT 2006
Unfortunately the ability of mapscript to deal with garbage collection
is still limited.
For example: the host language (in your case, python) will free an
object because it is no longer reachable without knowing that
mapscript still has references to it.
As soon as mapscript dereferences the pointer a segfault will occur.
As of now there are some methods that are safe to use in some ways,
but I can't provide a list right now.
HTH,
Umberto
On 10/17/06, Stéphane COLZY <stephane.colzy at magellium.fr> wrote:
>
>
>
>
> Hello,
>
>
>
> Have you already encountered this exception with Python/MapScript :
>
>
>
> Exception exceptions.AttributeError: "'NoneType' object has no attribute
> 'currentThread'" in <bound method mapObj.__del__ of <mapscript.mapObj; proxy
> of C mapObj instance at _10108002_p_map_obj>> ignored
>
>
>
> I'm using python/mapscript from MS4W 1.19 and Python 2.4.3
>
>
>
> The exception "randomly" appears in python debug mode only, in other cases
> python.exe just crashes.
>
>
>
> My guess is there's a segmentation fault when disposing mapscript objects,
> but I have no clues on how to troubleshoot this issue…
>
>
>
>
>
>
>
> Stéphane COLZY
>
> stephane.colzy at magellium.fr
> 05 61 28 81 22
>
> MAGELLIUM
> 10 avenue de l'Europe
> 31525 - Ramonville Saint Agne
>
> http://www.magellium.fr
>
>
More information about the MapServer-users
mailing list