Skip to content

Commit

Permalink
set spect to parent spec in _bind_instance_method
Browse files Browse the repository at this point in the history
  • Loading branch information
kramstrom committed Jul 2, 2024
1 parent 035e0a7 commit 448a9d2
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion modal/functions.py
Original file line number Diff line number Diff line change
Expand Up @@ -290,7 +290,7 @@ class _Function(_Object, type_prefix="fu"):
_web_url: Optional[str]
_function_name: Optional[str]
_is_method: bool
_spec: _FunctionSpec
_spec: _FunctionSpec = None
_tag: str
_raw_f: Callable[..., Any]
_build_args: dict
Expand Down Expand Up @@ -456,6 +456,7 @@ def _deps():
fun._parent = instance_service_function._parent
fun._app = class_bound_method._app
fun._all_mounts = class_bound_method._all_mounts # TODO: only used for mount-watching/modal serve
fun._spec = instance_service_function._parent._spec
return fun

@staticmethod
Expand Down

0 comments on commit 448a9d2

Please sign in to comment.