MCPcopy Create free account
hub / github.com/SplootCode/splootcode / get_method_params

Function get_method_params

python/module_loader.py:24–36  ·  view source on GitHub ↗
(thing)

Source from the content-addressed store, hash-verified

22 return short
23
24def get_method_params(thing):
25 params = []
26 sig = signature(thing)
27 for name in list(sig.parameters)[1:]:
28 param = sig.parameters[name]
29 res = {
30 'name': name,
31 'kind': param.kind.name,
32 }
33 if param.default != param.empty:
34 res['default'] = str(param.default)
35 params.append(res)
36 return params
37
38def get_func_params(thing):
39 params = []

Callers 2

get_value_dataFunction · 0.85
get_type_dataFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected