id,summary,reporter,owner,description,type,status,priority,milestone,component,version,severity,resolution,keywords,cc
2926,Python constructors don't fail properly,manderson,hobu,"The first time I tried out the Python bindings I used the following:

from osgeo import ogr[[BR]]
from osgeo.gdalconst import *

shpdrv = ogr.GetDriverByName(""ESRI Shapefile"")[[BR]]
dsloc = shpdrv.CreateDataSource(""outputDir"")
[[BR]]# etc etc... Until I was about to add geometry
[[BR]]tstGeo = ogr.Geometry()
[[BR]]tstGeo.AddPoint(0, 1, 1)

After the AddPoint call Python failed with a TypeError in ogr.py:
(snip) in AddPoint
    return _ogr.Geometry_AddPoint(*args, **kwargs)
TypeError: in method 'Geometry_AddPoint', argument 1 of type 'OGRGeometryShadow *'

I realize this is because the Geometry object is not being created in the intended way (I got excited...) but would it be worth it to add docstrings to the __init__ methods in the Python bindings (in general and specifically to ogr.Geometry.__init__) to provide a gentle introduction for GDAL/Python new people?  Perhaps throw a less vague error when this happens?

This is happening using gdal-1.6 and Python 2.6.1, both compiled with GCC 3.4.4 running under Cygwin.",defect,closed,low,1.7.0,PythonBindings,unspecified,minor,fixed,,warmerdam tamas rouault
