Opened 6 years ago
Last modified 3 years ago
#30519 new Cleanup/optimization
Add sanity checks to Django RasterField deserialization for rasters that are not fully managed through Django.
Reported by: | Daniel Wiesmann | Owned by: | nobody |
---|---|---|---|
Component: | GIS | Version: | dev |
Severity: | Normal | Keywords: | raster |
Cc: | Triage Stage: | Accepted | |
Has patch: | no | Needs documentation: | no |
Needs tests: | no | Patch needs improvement: | no |
Easy pickings: | no | UI/UX: | no |
Pull Requests: | How to create a pull request | ||
Description ¶
When using the RasterField for raster columns in PostGIS that are not fully managed by Django, the raster table could be of a type that is not supported by the GDALRaster. Examples are out-of-db rasters, or rasters that have an unsupported pixeltype (single bit rasters, 2 or 4 bit rasters).
A paragraph about this could be added to the documentation, and some sanity checks could be added to the raster deserialization here:
https://github.com/django/django/blob/master/django/contrib/gis/db/backends/postgis/pgraster.py
This ticket is related to https://code.djangoproject.com/ticket/30489 and https://github.com/django/django/pull/11381
According to the ticket's flags, the next step(s) to move this issue forward are:
- To provide a patch by sending a pull request. Claim the ticket when you start working so that someone else doesn't duplicate effort. Before sending a pull request, review your work against the patch review checklist. Check the "Has patch" flag on the ticket after sending a pull request and include a link to the pull request in the ticket comment when making that update. The usual format is:
[https://github.com/django/django/pull/#### PR]
.