Skip to content

Commit

Permalink
FEAT: get the path of a circuit component 5
Browse files Browse the repository at this point in the history
  • Loading branch information
gkorompi committed Jan 14, 2025
1 parent cdc8d2f commit dcf3bfa
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions src/ansys/aedt/core/modeler/circuits/object_3d_circuit.py
Original file line number Diff line number Diff line change
Expand Up @@ -1092,9 +1092,12 @@ def component_path(self):
if not component_data:
self._circuit_components._app.logger.warning("Component " + self.refdes + " has no path")
return False
for data in component_data:
if isinstance(data, list) and isinstance(data[0], str) and data[0] == "NAME:CosimDefinitions":
return (data[1][12][1].split(" ")[1])[1:-1]
if len(component_data[2][5]) == 0:
for data in component_data:
if isinstance(data, list) and isinstance(data[0], str) and data[0] == "NAME:CosimDefinitions":
return (data[1][12][1].split(" ")[1])[1:-1]
else:
return component_data[2][5]

Check warning on line 1100 in src/ansys/aedt/core/modeler/circuits/object_3d_circuit.py

View check run for this annotation

Codecov / codecov/patch

src/ansys/aedt/core/modeler/circuits/object_3d_circuit.py#L1100

Added line #L1100 was not covered by tests


class Wire(object):
Expand Down

0 comments on commit dcf3bfa

Please sign in to comment.