Skip to content

Commit a46e1e4

Browse files
committed
fix(goatlib): increase tile size limit to prevent errors on dense polygon layers
1 parent b6edc76 commit a46e1e4

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

packages/python/goatlib/src/goatlib/io/pmtiles.py

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -561,10 +561,13 @@ def _run_tippecanoe(
561561
if label_anchor:
562562
# Label anchor settings: one point per polygon, no clustering.
563563
# tippecanoe's --convert-polygons-to-label-points already handles
564-
# optimal placement. We just need to keep all features at all zooms.
564+
# optimal placement. Use higher tile size limit to avoid "tile too big"
565+
# errors on dense polygon layers, and allow dropping at low zooms.
565566
cmd.extend(
566567
[
567-
"-r1", # Keep at least 1 feature per tile
568+
"-r1", # Minimal drop rate (keep as much as possible)
569+
"-M",
570+
"2000000", # 2MB tile size limit (default 500KB too small for dense layers)
568571
"--extend-zooms-if-still-dropping",
569572
]
570573
)

0 commit comments

Comments
 (0)