Skip to content

Commit 095ac87

Browse files
committed
TO REMOVE: for debugging github ci on Windows
1 parent 8c9020a commit 095ac87

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

pypdf/_page.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -2216,13 +2216,13 @@ def __getitem__(
22162216
cls = type(self)
22172217
return cls(indices.__len__, lambda idx: self[indices[idx]])
22182218
if not isinstance(index, int):
2219-
raise TypeError("sequence indices must be integers")
2219+
raise TypeError(f"sequence indices must be integers (got index = {index})")
22202220
len_self = len(self)
22212221
if index < 0:
22222222
# support negative indexes
22232223
index = len_self + index
22242224
if index < 0 or index >= len_self:
2225-
raise IndexError("sequence index out of range")
2225+
raise IndexError(f"sequence index out of range (got size = {len_self}, index: {index})")
22262226
return self.get_function(index)
22272227

22282228
def __delitem__(self, index: Union[int, slice]) -> None:

0 commit comments

Comments
 (0)