Skip to content

Commit

Permalink
fix: prospector and mypy
Browse files Browse the repository at this point in the history
  • Loading branch information
jagalindo committed Aug 22, 2024
1 parent 7b205e8 commit 4ae1d5c
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions flamapy/core/discover.py
Original file line number Diff line number Diff line change
Expand Up @@ -179,14 +179,14 @@ def use_operation(self, src: VariabilityModel, operation_name: str) -> Operation
operation = plugin.get_operation(operation_name)
return plugin.use_operation(operation, src)

# pylint: disable=too-many-arguments
def use_operation_from_vm(
self,
operation_name: str,
vm_orig: VariabilityModel,
plugin_name: Optional[str] = None,
configuration_file: Optional[str] = None,
is_full: Optional[bool] = False

) -> Any:

if operation_name not in self.get_name_operations():
Expand Down Expand Up @@ -215,13 +215,15 @@ def use_operation_from_vm(
raise ConfigurationNotFound()
configuration = self.__transform_to_model_from_file(configuration_file)
configuration = cast(Configuration, configuration)
configuration.set_full(is_full)
is_full_value = is_full if is_full is not None else False
configuration.set_full(is_full_value)
operation.set_configuration(configuration)

operation = plugin.use_operation(operation, vm_temp)

return operation.get_result()

# pylint: disable=too-many-arguments
def use_operation_from_file(
self,
operation_name: str,
Expand Down Expand Up @@ -257,7 +259,8 @@ def use_operation_from_file(
raise ConfigurationNotFound()
configuration = self.__transform_to_model_from_file(configuration_file)
configuration = cast(Configuration, configuration)
configuration.set_full(is_full)
is_full_value = is_full if is_full is not None else False
configuration.set_full(is_full_value)
operation.set_configuration(configuration)

operation = plugin.use_operation(operation, vm_temp)
Expand Down

0 comments on commit 4ae1d5c

Please sign in to comment.