Skip to content

Commit

Permalink
chore: auto fixes from pre-commit hooks
Browse files Browse the repository at this point in the history
  • Loading branch information
pre-commit-ci[bot] committed Feb 11, 2025
1 parent 4e39e66 commit c4f97c5
Showing 1 changed file with 17 additions and 9 deletions.
26 changes: 17 additions & 9 deletions src/ansys/geometry/core/tools/repair_tools.py
Original file line number Diff line number Diff line change
Expand Up @@ -475,7 +475,7 @@ def find_and_fix_short_edges(
The maximum length of the edges. By default, 0.0.
comprehensive_result : bool, optional
Determines whether the repair tool will attempt to fix all problem areas at once (false, default), or each individually (true).
Fixing each area individually may take longer, but gives a more comprehensive result about the repair operation's success.
Fixing each area individually may take longer, but gives a more comprehensive result about the repair operation's success.
Returns
-------
Expand All @@ -495,7 +495,7 @@ def find_and_fix_short_edges(
FindShortEdgesRequest(
selection=[body.id for body in bodies],
max_edge_length=DoubleValue(value=length),
comprehensive=comprehensive_result
comprehensive=comprehensive_result,
)
)

Expand All @@ -512,7 +512,9 @@ def find_and_fix_short_edges(

@protect_grpc
@min_backend_version(25, 2, 0)
def find_and_fix_extra_edges(self, bodies: list["Body"], comprehensive_result: bool = False) -> RepairToolMessage:
def find_and_fix_extra_edges(
self, bodies: list["Body"], comprehensive_result: bool = False
) -> RepairToolMessage:
"""Find and fix the extra edge problem areas.
Notes
Expand All @@ -527,7 +529,7 @@ def find_and_fix_extra_edges(self, bodies: list["Body"], comprehensive_result: b
The maximum length of the edges.
comprehensive_result : bool, optional
Determines whether the repair tool will attempt to fix all problem areas at once (false, default), or each individually (true).
Fixing each area individually may take longer, but gives a more comprehensive result about the repair operation's success.
Fixing each area individually may take longer, but gives a more comprehensive result about the repair operation's success.
Returns
-------
Expand All @@ -544,8 +546,7 @@ def find_and_fix_extra_edges(self, bodies: list["Body"], comprehensive_result: b

response = self._repair_stub.FindAndFixExtraEdges(
FindExtraEdgesRequest(
selection=[body.id for body in bodies],
comprehensive=comprehensive_result
selection=[body.id for body in bodies], comprehensive=comprehensive_result
)
)

Expand All @@ -563,7 +564,11 @@ def find_and_fix_extra_edges(self, bodies: list["Body"], comprehensive_result: b
@protect_grpc
@min_backend_version(25, 2, 0)
def find_and_fix_split_edges(
self, bodies: list["Body"], angle: Real = 0.0, length: Real = 0.0, comprehensive_result: bool = False
self,
bodies: list["Body"],
angle: Real = 0.0,
length: Real = 0.0,
comprehensive_result: bool = False,
) -> RepairToolMessage:
"""Find and fix the split edge problem areas.
Expand All @@ -581,7 +586,7 @@ def find_and_fix_split_edges(
The maximum length of the edges. By default, 0.0.
comprehensive_result : bool, optional
Determines whether the repair tool will attempt to fix all problem areas at once (false, default), or each individually (true).
Fixing each area individually may take longer, but gives a more comprehensive result about the repair operation's success.
Fixing each area individually may take longer, but gives a more comprehensive result about the repair operation's success.
Returns
Expand All @@ -605,7 +610,10 @@ def find_and_fix_split_edges(

response = self._repair_stub.FindAndFixSplitEdges(
FindSplitEdgesRequest(
bodies_or_faces=body_ids, angle=angle_value, distance=length_value, comprehensive=comprehensive_result
bodies_or_faces=body_ids,
angle=angle_value,
distance=length_value,
comprehensive=comprehensive_result,
)
)

Expand Down

0 comments on commit c4f97c5

Please sign in to comment.