Skip to content

Commit

Permalink
make views respect order
Browse files Browse the repository at this point in the history
  • Loading branch information
nwlandry committed Oct 25, 2023
1 parent 16e39f6 commit 3ace9e2
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion xgi/core/views.py
Original file line number Diff line number Diff line change
Expand Up @@ -511,7 +511,7 @@ def from_view(cls, view, bunch=None):
wrong = bunch - all_ids
if wrong:
raise IDNotFound(f"IDs {wrong} not in the hypergraph")
newview._ids = bunch
newview._ids = [i for i in view._id_dict if i in bunch]
return newview

def _from_iterable(self, it):
Expand Down

0 comments on commit 3ace9e2

Please sign in to comment.