If you do a mouse drag selection (rectangular selection) over BrepEdges, edges will be selected once for every face that they touch. This is not an intuitive result. Maybe there is a good reason for this to happen, but for me it just caused bugs.
Here is the code. To replicate the behavior I described, try selecting internal edges using a rectangular selection. If you then print the number of selected objects, or print the (Guid, ComponentIndex) pairs, you will see the duplicates.
I did end up using a HashSet to filter out duplicates. I just thought it might be good to give some feedback on what I thought was a strange API so that perhaps others don’t have to trouble shoot this in the future.