Skip to content

Commit

Permalink
Index: use len in repr (#323)
Browse files Browse the repository at this point in the history
  • Loading branch information
adamjstewart authored Jul 11, 2024
1 parent 47dae12 commit d42650c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion rtree/index.py
Original file line number Diff line number Diff line change
Expand Up @@ -297,7 +297,7 @@ def __len__(self) -> int:
return 0

def __repr__(self) -> str:
return f"rtree.index.Index(bounds={self.bounds}, size={self.get_size()})"
return f"rtree.index.Index(bounds={self.bounds}, size={len(self)})"

def __getstate__(self) -> dict[str, Any]:
state = self.__dict__.copy()
Expand Down

0 comments on commit d42650c

Please sign in to comment.