Skip to content

Commit

Permalink
Additional information in case of error while reading mesh file
Browse files Browse the repository at this point in the history
  • Loading branch information
heySourabh committed Feb 6, 2024
1 parent d4361ed commit 2a8e867
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/main/mesh/factory/Unstructured3DMesh.java
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,8 @@ public Unstructured3DMesh(File meshFile, int numVars, Map<String, BoundaryCondit
faceNodes[ni] = nodes.get(connectivity[ni + 1]);
}
Face bndFace = search(faceNodes, allBoundaryFaces)
.orElseThrow(() -> new IllegalStateException("Couldn't locate boundary face in mesh."));
.orElseThrow(() -> new IllegalStateException("Couldn't locate boundary face in mesh.\n" +
"The error occurred while reading '" + bndName + "' boundary."));
bndFace.right = Mesh.ghostCell(bndFace.left, bndFace);
bndFaces.add(bndFace);
}
Expand Down

0 comments on commit 2a8e867

Please sign in to comment.