Skip to content

Commit

Permalink
Fix for a tiny typo in _MinLengthValidator (#1209)
Browse files Browse the repository at this point in the history
* tiny typo fix for min length validator's error string

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
  • Loading branch information
ckutlu and pre-commit-ci[bot] authored Nov 30, 2023
1 parent 0d1be89 commit 01413df
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/attr/validators.py
Original file line number Diff line number Diff line change
Expand Up @@ -550,7 +550,7 @@ def __call__(self, inst, attr, value):
We use a callable class to be able to change the ``__repr__``.
"""
if len(value) < self.min_length:
msg = f"Length of '{attr.name}' must be => {self.min_length}: {len(value)}"
msg = f"Length of '{attr.name}' must be >= {self.min_length}: {len(value)}"
raise ValueError(msg)

def __repr__(self):
Expand Down

0 comments on commit 01413df

Please sign in to comment.