Skip to content

Commit 35f4a00

Browse files
committed
Fix variable name, log error
1 parent 265a8a7 commit 35f4a00

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

tasks/make_boundaries/src/usecases/make_admin_labels.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ def get_label_point(x: geometry.Polygon | geometry.MultiPolygon):
1818

1919
xfact = 0.7
2020
geom = (
21-
max(x.geoms, key=lambda x: x.area)
21+
max(x.geoms, key=lambda g: g.area)
2222
if isinstance(x, geometry.MultiPolygon)
2323
else x
2424
)
@@ -132,8 +132,8 @@ def make_admin_labels(
132132
make_versatiles(
133133
json_path, versatiles_path, tilejson_path, date, ["--base-zoom=5"]
134134
)
135-
except Exception:
136-
print(f"Failed to build {versatiles_path}")
135+
except Exception as e:
136+
print(f"Failed to build {versatiles_path}: {e!r}")
137137
return []
138138

139139
return [versatiles_path]

0 commit comments

Comments
 (0)