Skip to content

Commit

Permalink
[pre-commit.ci] auto fixes from pre-commit.com hooks
Browse files Browse the repository at this point in the history
for more information, see https://pre-commit.ci
  • Loading branch information
pre-commit-ci[bot] committed Sep 7, 2023
1 parent 12d8b43 commit 794a1d7
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 5 deletions.
4 changes: 3 additions & 1 deletion Tests/test_file_eps.py
Original file line number Diff line number Diff line change
Expand Up @@ -413,5 +413,7 @@ def test_timeout(test_file):
def test_boundary_box_in_trailer(trailer_image_file, header_image_file):
# Check whether boundary boxes which are specified in the trailer are parsed
# just like boundary boxes specified in the header
with Image.open(trailer_image_file) as trailer_image, Image.open(header_image_file) as header_image:
with Image.open(trailer_image_file) as trailer_image, Image.open(
header_image_file
) as header_image:
assert trailer_image.size == header_image.size
5 changes: 1 addition & 4 deletions src/PIL/EpsImagePlugin.py
Original file line number Diff line number Diff line change
Expand Up @@ -414,9 +414,7 @@ def _read_boundary_box(self, v, offset, length):
# put floating point values there anyway.
box = [int(float(i)) for i in v.split()]
self._size = box[2] - box[0], box[3] - box[1]
self.tile = [
("eps", (0, 0) + self.size, offset, (length, box))
]
self.tile = [("eps", (0, 0) + self.size, offset, (length, box))]
except Exception:
pass

Expand All @@ -435,7 +433,6 @@ def load_seek(self, *args, **kwargs):
pass



# --------------------------------------------------------------------


Expand Down

0 comments on commit 794a1d7

Please sign in to comment.