diff --git a/packages/syft/src/syft/service/service.py b/packages/syft/src/syft/service/service.py index c28fc1157d1..e7ccd5c25ad 100644 --- a/packages/syft/src/syft/service/service.py +++ b/packages/syft/src/syft/service/service.py @@ -340,6 +340,7 @@ def wrapper(func: Any) -> Callable: _path = class_name + "." + func_name signature = inspect.signature(func) signature = signature_remove_self(signature) + signature_with_context = deepcopy(signature) signature = signature_remove_context(signature) input_signature = deepcopy(signature) @@ -353,7 +354,7 @@ def _decorator(self: Any, *args: Any, **kwargs: Any) -> Callable: ) if autosplat is not None and len(autosplat) > 0: args, kwargs = reconstruct_args_kwargs( - signature=input_signature, + signature=signature_with_context, autosplat=autosplat, args=args, kwargs=kwargs, diff --git a/packages/syft/src/syft/service/settings/settings_service.py b/packages/syft/src/syft/service/settings/settings_service.py index f93a019e26a..80ac0cdcc55 100644 --- a/packages/syft/src/syft/service/settings/settings_service.py +++ b/packages/syft/src/syft/service/settings/settings_service.py @@ -165,7 +165,7 @@ def allow_guest_signup( result = method(context=context, settings=settings) - if result.is_err(): + if isinstance(result, SyftError): return SyftError(message=f"Failed to update settings: {result.err()}") message = "enabled" if enable else "disabled"