Improve error logs for failing profiles #6131

This commit is contained in:
Andrej730
2025-02-10 15:14:50 +05:00
parent 65d65972ac
commit 8e9d4be55d
2 changed files with 3 additions and 3 deletions
@@ -278,7 +278,7 @@ def get_vertical_profile_preview_data(
verts = shape.verts verts = shape.verts
if not verts: if not verts:
raise RuntimeError("Profile shape has no vertices, it probably is invalid.") raise RuntimeError(f"Profile shape has no vertices, it probably is invalid: '{profile}'.")
edges = shape.edges edges = shape.edges
@@ -394,7 +394,7 @@ def get_horizontal_profile_preview_data(context, relating_type):
verts = shape.verts verts = shape.verts
if not verts: if not verts:
raise RuntimeError("Profile shape has no vertices, it probably is invalid.") raise RuntimeError(f"Profile shape has no vertices, it probably is invalid: '{profile}'.")
edges = shape.edges edges = shape.edges
+1 -1
View File
@@ -47,7 +47,7 @@ class Profile(bonsai.core.tool.Profile):
verts = shape.verts verts = shape.verts
if not verts: if not verts:
raise RuntimeError("Profile shape has no vertices, it probably is invalid.") raise RuntimeError(f"Profile shape has no vertices, it probably is invalid: '{profile}'.")
edges = shape.edges edges = shape.edges