Skip to content

Commit

Permalink
build_conf.py: fix lint warning
Browse files Browse the repository at this point in the history
The existing source code has failed to pass the Flake8 check in
build_conf.py:
Do not compare types, use 'isinstance()' (E721)

That blocks merge of the other changes. This patch is intended to fix
the above-mentioned lint warning.

Signed-off-by: Mykhailo Androsiuk <[email protected]>
Reviewed-by: Volodymyr Babchuk <[email protected]>
  • Loading branch information
Mykhailo Androsiuk committed Oct 25, 2023
1 parent d60aa3c commit cb3b3b8
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions moulin/build_conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -38,8 +38,7 @@ def apply_overrides(self, node: MappingNode):

@staticmethod
def _override(remote_node: Node, local_node: Node):
# pylint: disable=unidiomatic-typecheck
if type(remote_node) != type(local_node):
if type(remote_node) is not type(local_node):
raise YAMLProcessingError(
f"Incompatible types {type(remote_node)} and " +
f" {type(local_node)} while trying to apply overrides", local_node.start_mark)
Expand Down

0 comments on commit cb3b3b8

Please sign in to comment.