elgeopaso.jobs.management.commands.map_builder module

class elgeopaso.jobs.management.commands.map_builder.Command(stdout=None, stderr=None, no_color=False, force_color=False)[source]

Bases : django.core.management.base.BaseCommand

args = '<foo bar ...>'
build_geojson_fr_departements(in_geojson)[source]

Parse input GeoJSON and update needed values to display maps.

Paramètres

in_geojson (Path) – Path to the input GeoJSON

external_downloader(overwrite=False)[source]

Download external files.

Paramètres

overwrite (bool) – option to overwrite existing files. Defaults to: False - optional

Renvoie

list of downloaded files

Type renvoyé

list

handle(*args, **options)[source]

Download required files and launch GeoJSON build.

help = '\n                Commands to generate geojson files used for map visualization.\n           '
url_to_file(url, final_file, timeout=60)[source]

Download file from URL to local storage.

Source: https://stackoverflow.com/a/16696317/2556577

Paramètres
  • url (str) – [description]

  • final_file (Path) – [description]

  • timeout (int) – [description]. Defaults to: 60 - optional