Skip to content

change: enable chained-comparison Pylint check #940

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Jul 16, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion .pylintrc
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,6 @@ disable=
cyclic-import, # TODO: Resolve cyclic imports
no-self-use, # TODO: Convert methods to functions where appropriate
consider-using-ternary, # TODO: Consider ternary expressions
chained-comparison, # TODO: Simplify chained comparison between operands
too-many-branches, # TODO: Simplify or ignore as appropriate
missing-docstring, # TODO: Fix missing docstring

Expand Down
2 changes: 1 addition & 1 deletion src/sagemaker/parameter.py
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ def is_valid(self, value):
Returns:
bool: True if valid, False otherwise.
"""
return value >= self.min_value and value <= self.max_value
return self.min_value <= value <= self.max_value

@classmethod
def cast_to_type(cls, value):
Expand Down