feat: node/element selection commands returning selected ids#3636
Conversation
|
Thanks for opening a Pull Request. If you want to perform a review write a comment saying: @ansys-reviewer-bot review |
for more information, see https://pre-commit.ci
germa89
left a comment
There was a problem hiding this comment.
thank you a lot for this @moe-ad :). However, for this to be approved, you need to add some unit tests. I'm sure you know the procedure, but in case you have any doubt please check: https://mapdl.docs.pyansys.com/version/stable/getting_started/develop_pymapdl.html#unit-testing
Which you can reach from main documentation page https://mapdl.docs.pyansys.com :
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #3636 +/- ##
==========================================
- Coverage 87.08% 87.06% -0.02%
==========================================
Files 187 187
Lines 14679 14683 +4
==========================================
+ Hits 12783 12784 +1
- Misses 1896 1899 +3 |
|
@germa89 , thanks for the guide. I have added the tests. |
|
Congrats on this, @moe-ad 🚀 |


Description
Currently, commands such as
mapdl.nsel()ormapdl.esel()will return a numpy array of selected objects' IDs. This is extremely useful when scripting since the selected IDs can be saved in a variable to be accessed later. Similar commands likemapdl.esln()ormapdl.nsle()do not have this behavior. Instead they return some selection status string from the running mapdl instance.This PR adds the described functionality to the
mapdl.esln()andmapdl.nsle()commands.Issue linked
This PR will close #3635
Checklist
draftif it is not ready to be reviewed yet.feat: adding new MAPDL command)