fix(assembly): handle non-standard datum element types in Distance joint classification #319
Reference in New Issue
Block a user
Delete Branch "fix/datum-plane-classification-all-hierarchies"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Problem
Follow-up to #318. The previous fix broadened datum detection to check
isDatumPlane()instead of justisDerivedFrom<App::Plane>(), but still gated the check ontype.empty(). This missed PartDesign datum planes referenced through a body, where the sub-name looks like:splitSubNameextracts"Plane"as the element type — not empty, but also not a standard geometry type (Face/Edge/Vertex).Part::Datum::getSubObject()ignores this trailing element entirely, butgetElementTypeFromProp()still sees it.Since
"Plane"is not empty, the datum detection was skipped, and since it's not Face/Edge/Vertex, the main geometry chain couldn't classify it either →DistanceType::Other→ wrong fallback.Symptoms
unhandled DistanceType Otherafter fix(assembly): classify datum planes from all class hierarchies in Distance joints (#318)Fix
Replace
type.empty()gate withisNonGeomElement(type)— a lambda that checkstype != "Face" && type != "Edge" && type != "Vertex". This catches:.)"Plane"(PartDesign datums referenced through body)4f658b13f9to14ee8c673f