Skip to content

Commit 2ab8b5f

Browse files
authored
[3.1.x] Refs #32230 -- Fixed LayerMapping example in GeoDjango tutorial.
LayerMapping.data_source doesn't support pathlib.Path(). Regression in 26554cf. Follow up to e46ca51.
1 parent 3a70c36 commit 2ab8b5f

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

docs/ref/contrib/gis/tutorial.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -453,7 +453,7 @@ with the following code::
453453
world_shp = Path(__file__).resolve().parent / 'data' / 'TM_WORLD_BORDERS-0.3.shp'
454454

455455
def run(verbose=True):
456-
lm = LayerMapping(WorldBorder, world_shp, world_mapping, transform=False)
456+
lm = LayerMapping(WorldBorder, str(world_shp), world_mapping, transform=False)
457457
lm.save(strict=True, verbose=verbose)
458458

459459
A few notes about what's going on:

0 commit comments

Comments
 (0)