#36196: django.contrib.gis.GDALRaster support for driver configuration options
--------------------------------+------------------------------------------
     Reporter:  Jordi Castells  |                    Owner:  Jordi Castells
         Type:  New feature     |                   Status:  assigned
    Component:  GIS             |                  Version:  5.1
     Severity:  Normal          |               Resolution:
     Keywords:                  |             Triage Stage:  Accepted
    Has patch:  0               |      Needs documentation:  0
  Needs tests:  0               |  Patch needs improvement:  0
Easy pickings:  0               |                    UI/UX:  0
--------------------------------+------------------------------------------
Comment (by Jordi Castells):

 I see some possible inconsistencies rising from this:

 `GDALRaster(ds_input, mode)`

 My first instinct was to extend this to be more akin to a `GDAL OpenEx` ->
 `GdalRaster(ds_input, mode, papsz_open_options=None)`

 But, `ds_input` can be one of the following
  * `string` -> Assume  apath
  * `bytes` -> Assume in memory raster
  * `dict` -> Definition to create a raster from scratch

 We already have possibility to pass `papsz_options` to the `ds_input` when
 it is a `dict`.

 So that would clash with my original intent.

 I think what makes more sense is to remove that
 `dict["papsz_open_options"]` and all calls to `GDALRaster` could use the
 different open options available. Open an existing raster file could
 provide extra open options, and creating a raster from scratch could
 provide the current dict + pass some extra information via the optional
 parameter. Although that would mean breaking the current use of `creating
 a new raster`.

 We could also go with the two options (`dict["papsz_*"]` and optional
 `papsz_*` parameter) but that could make creating rasters from scratch
 more confusing since there are two places where to define `papsz` and only
 one right one.
-- 
Ticket URL: <https://code.djangoproject.com/ticket/36196#comment:4>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion visit 
https://groups.google.com/d/msgid/django-updates/0107019527c1d813-558d9fb2-59ac-4cc2-90cd-ffe81a27f90b-000000%40eu-central-1.amazonses.com.

Reply via email to