artemp/tickets2issues — Issue #610: using mapnik::boolean type for estimate_extent?
Author: artemp
Created: 2011-10-11 15:27:49+00:00
State: closed
Labels: PostGIS_Input_Driver

Big points to alberto for catching and fixing in r1700 a problem I introduced in r1632 when I lost quotes needed for the proper usage of the estimated_extent function.

I have a long set of postgis tests that should have caught this but didn't.

The reason was that I was passing, in python (all the tests are in python) something like:

{{{
ds = mapnik.PostGIS(dbname='osm_belgium',table='planet_osm_line',estimate_extent=True)
}}}

and since we get() 'estimate_extent' as a string that was evaluating to '1' and not 'true'.

I can't see any reason why we'd want to have the behavior like this, but I may be missing something. I'll attach my fix for review.