MCPcopy Create free account
hub / github.com/YuminosukeSato/ironkernel / reject_callable_args_for_spec

Function reject_callable_args_for_spec

src/python/py_runtime.rs:34–44  ·  view source on GitHub ↗
(
    args: &Bound<'_, PyTuple>,
    kwargs: Option<&Bound<'_, PyDict>>,
)

Source from the content-addressed store, hash-verified

32}
33
34fn reject_callable_args_for_spec(
35 args: &Bound<'_, PyTuple>,
36 kwargs: Option<&Bound<'_, PyDict>>,
37) -> PyResult<()> {
38 if args.is_empty() && kwargs.is_none() {
39 return Ok(());
40 }
41 Err(PyErr::new::<pyo3::exceptions::PyTypeError, _>(
42 "go() only accepts *args and **kwargs for Python callables",
43 ))
44}
45
46enum CallableOutcome {
47 Cancelled,

Callers 1

goMethod · 0.85

Calls 1

is_emptyMethod · 0.80

Tested by

no test coverage detected