You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
ValueErrorTraceback (mostrecentcalllast)
24ExtensionLine(border=edg, offset=10, draft=std)
25outside_curve=e_line.edges().sort_by(Axis.X)[-1]
--->26ExtensionLine(border=outside_curve, offset=10, label_angle=True, draft=std)
28# [TechnicalDrawing]29withBuildSketch() astech_drawing:
Filec:\Users\someuser\.conda\envs\ocp_vscode\Lib\site-packages\build123d\drafting.py:562, inExtensionLine.__init__(self, border, offset, draft, sketch, label, arrows, tolerance, label_angle, project_line, mode)
560e_line_shape=sweep(line_pen, extension_line, mode=Mode.PRIVATE)
561e_lines.append(e_line_shape)
-->562d_line=DimensionLine(
563dimension_path,
564draft,
565sketch,
566label,
567arrows,
568tolerance,
569label_angle,
570mode=Mode.PRIVATE,
571 )
572self.dimension=d_line.dimension#: length of the dimension574e_line_sketch=Sketch(children=e_lines+d_line.faces())
Filec:\Users\someuser\.conda\envs\ocp_vscode\Lib\site-packages\build123d\drafting.py:410, inDimensionLine.__init__(self, path, draft, sketch, label, arrows, tolerance, label_angle, mode)
406iflabel_length+arrows.count(True) *draft.arrow_length<path_length:
407shaft_length= (path_length-label_length) /2-draft.pad_around_text408shaft_pair= [
409path_obj.trim(0.0, shaft_length/path_length),
-->410path_obj.trim(1.0-shaft_length/path_length, 1.0),
411 ]
412else:
413shaft_length=2*draft.arrow_lengthFilec:\Users\someuser\.conda\envs\ocp_vscode\Lib\site-packages\build123d\topology.py:7785, inWire.trim(self, start, end)
7783u_start=edge.param_at_point(trim_start_point)
7784u_end=edge.param_at_point(trim_end_point)
->7785edge=edge.trim(u_start, u_end)
7786elifcontains_start:
7787u_value=edge.param_at_point(trim_start_point)
Filec:\Users\someuser\.conda\envs\ocp_vscode\Lib\site-packages\build123d\topology.py:4609, inEdge.trim(self, start, end)
4594"""trim 4595 4596 Create a new edge by keeping only the section between start and end. (...) 4606 Edge: trimmed edge 4607 """4608ifstart>=end:
->4609raiseValueError(f"start ({start}) must be less than end ({end})")
4611new_curve=BRep_Tool.Curve_s(
4612copy.deepcopy(self).wrapped, self.param_at(0), self.param_at(1)
4613 )
4614parm_start=self.param_at(start)
ValueError: start (0.8165271836783728) mustbelessthanend (0.0)
I have also observed some non-repeatable sporadic behavior in which this fails on the first call to ExtensionLine (in the same way as above). Perhaps the line is reversed at some point?
The text was updated successfully, but these errors were encountered:
This code is adapted from docs/objects_2d.py:
Returns:
I have also observed some non-repeatable sporadic behavior in which this fails on the first call to ExtensionLine (in the same way as above). Perhaps the line is reversed at some point?
The text was updated successfully, but these errors were encountered: