Problem with mesh join

Hi all,

I’m trying to turn a terrain mesh into a closed solid. Steps:

  1. Take the terrain mesh, copy it and move on -Z for the bottom.
  2. Extract naked edges of the top, loft to the bottom boundary, convert to mesh.
  3. Merge top + bottom + sides → Mesh Join → Weld / Combine & Clean.

Is Mesh Closed always returns False. I think the vertices along the seams don’t match between the lofted sides and the terrain boundary, but I can’t figure out the clean way to fix it.

Script attached — any help appreciated!

  1. mesh join problem.gh (635.7 KB)

Here’s a solution without pufferfish

mesh join no puff.gh (649.7 KB)