Skip to content

Commit

Permalink
Change occurrence of % to f-string
Browse files Browse the repository at this point in the history
  • Loading branch information
DimitriPapadopoulos committed Aug 10, 2024
1 parent 0ceb315 commit 5bd0eec
Showing 1 changed file with 3 additions and 8 deletions.
11 changes: 3 additions & 8 deletions numcodecs/zfpy.py
Original file line number Diff line number Diff line change
Expand Up @@ -102,11 +102,6 @@ def decode(self, buf, out=None):
return dec

def __repr__(self):
r = "%s(mode=%r, tolerance=%s, rate=%s, precision=%s)" % (
type(self).__name__,
self.mode,
self.tolerance,
self.rate,
self.precision,
)
return r
return (f"{type(self).__name__}(mode={self.mode:!r}, "
f"tolerance={self.tolerance}, rate={self.rate}, "
f"precision={self.precision})")

0 comments on commit 5bd0eec

Please sign in to comment.