Code

Opened 6 years ago

Closed 6 years ago

#7434 closed (fixed)

Add an option to disable GDAL

Reported by: rcoup Owned by: jbronn
Component: GIS Version: gis
Severity: Keywords: gdal settings disable
Cc: Triage Stage: Ready for checkin
Has patch: yes Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: UI/UX:

Description

libgdal connects to a massive number of other libraries which collectively use a tonne of RAM. This is further compounded in distribution releases of GDAL (eg. Debian & Ubuntu) since they tend to include nearly every option. Since it's imported by gis/models.py the RAM is consumed regardless of whether any GDAL features are later used.

Batteries included is good, so I wonder whether we can set a NO_GDAL option so people who want to disable it and understand the consequences can, as an optional setting or environment variable? Happy to write a patch, just want an opinion on options :)

Attachments (1)

7434.0.diff (776 bytes) - added by rcoup 6 years ago.
Doc patch

Download all attachments as: .zip

Change History (6)

comment:1 Changed 6 years ago by jbronn

  • Needs documentation unset
  • Needs tests unset
  • Patch needs improvement unset

Have you tried setting GDAL_LIBRARY_PATH in your settings to a non-existent file? Afterwords, an import of GDAL stuff should fail, and thus HAS_GDAL would be false.

comment:2 Changed 6 years ago by jbronn

  • Keywords gdal settings disable added
  • Owner changed from nobody to jbronn
  • Version changed from SVN to gis

Changed 6 years ago by rcoup

Doc patch

comment:3 Changed 6 years ago by rcoup

Works fine :)

7434.0.diff is a patch to gdal/__init__.py adding a note about the GDAL_LIBRARY_PATH setting.

comment:4 Changed 6 years ago by Simon Greenhill

  • Has patch set
  • Triage Stage changed from Unreviewed to Ready for checkin

comment:5 Changed 6 years ago by jbronn

  • Resolution set to fixed
  • Status changed from new to closed

Fixed in r7665.

Add Comment

Modify Ticket

Change Properties
<Author field>
Action
as closed
as The resolution will be set. Next status will be 'closed'
The resolution will be deleted. Next status will be 'new'
Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.