File tree Expand file tree Collapse file tree 4 files changed +997
-257
lines changed
Expand file tree Collapse file tree 4 files changed +997
-257
lines changed Submodule
eigen updated from 9099c5e to b5feca5
Original file line number Diff line number Diff line change 88import diffCheck .df_util
99import diffCheck .df_transformations
1010
11+ from Grasshopper .Kernel import GH_RuntimeMessageLevel as RML
12+
1113
1214@dataclass
1315class JointDetector :
@@ -153,10 +155,11 @@ def run(self) :
153155 if f_b is not None :
154156 if f_b .IsSolid :
155157 self ._cuts .append (f_b )
156- for f_b in non_flat_faces_b :
157- if f_b is not None :
158- if f_b .IsSolid :
159- self ._holes .append (f_b )
158+ if non_flat_faces_b is not None and len (non_flat_faces_b ) > 0 :
159+ for f_b in non_flat_faces_b :
160+ if f_b is not None :
161+ if f_b .IsSolid :
162+ self ._holes .append (f_b )
160163
161164 ############################################################################
162165 # 3. Sort faces from joints and faces from sides
@@ -195,4 +198,7 @@ def run(self) :
195198 if not is_joint :
196199 self ._faces .append ([f , None ])
197200
201+ if self ._faces is None or len (self ._faces ) == 0 :
202+ ghenv .Component .AddRuntimeMessage (RML .Error , "No faces found after joint detection." )
203+
198204 return self ._faces
Original file line number Diff line number Diff line change 99import diffCheck
1010import diffCheck .df_geometries
1111
12- import sys
13- import importlib
14- for key in list (sys .modules .keys ()):
15- if "diffCheck" in key :
16- importlib .reload (sys .modules [key ])
12+ print (diffCheck .__version__ )
13+
1714
1815if __name__ == "__main__" :
1916 """
2219 :param i_export_dir: directory to export the xml
2320 :param i_dump: whether to dump the xml
2421 """
22+ # data_faces = diffCheck.df_joint_detector.JointDetector(i_breps[0]).run()
2523 # beams
2624 beams = []
2725 for brep in i_breps :
You can’t perform that action at this time.
0 commit comments