Skip to content

Commit

Permalink
chore: enable 'warn_redundant_casts' for mypy
Browse files Browse the repository at this point in the history
Enable 'warn_redundant_casts'for mypy and resolve one issue.
  • Loading branch information
JohnVillalovos committed Dec 6, 2021
1 parent a86d049 commit f40e9b3
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion gitlab/v4/objects/keys.py
Expand Up @@ -31,4 +31,4 @@ def get(
server_data = self.gitlab.http_get(self.path, **kwargs)
if TYPE_CHECKING:
assert isinstance(server_data, dict)
return cast(Key, self._obj_cls(self, server_data))
return self._obj_cls(self, server_data)
2 changes: 1 addition & 1 deletion pyproject.toml
Expand Up @@ -12,6 +12,7 @@ disallow_incomplete_defs = true
disallow_subclassing_any = true
disallow_untyped_decorators = true
disallow_untyped_defs = true
warn_redundant_casts = true
warn_unused_configs = true
warn_unused_ignores = true

Expand All @@ -21,7 +22,6 @@ warn_unused_ignores = true
# no_implicit_optional = true
# no_implicit_reexport = true
# strict_equality = true
# warn_redundant_casts = true
# warn_return_any = true

[[tool.mypy.overrides]] # Overrides for currently untyped modules
Expand Down

0 comments on commit f40e9b3

Please sign in to comment.