Skip to content

ConduitPartialBlock

Same as ConduitBlock, but it is used as placeholder for non-existing blocks.

ALL partial blocks means non-existing blocks and they doesn't have any functionality. If that's the thing that you don't want, please refer to ConduitBlock class instead.

Danger

It is discouraged to create instance of this block manually, because it is only returned when searching for a non-existing block.

Attributes:

Name Type Description
name str

A custom name for the block.

category Optional[str]

Name of the category for the block. It can point to a non-existing category.

description: Optional[str] inherited property readonly

Returns the docstring of function.

Returns:

Type Description
Optional[str]

Documentation string of the inner function. If there is no documentation string, it will be None.

display_name: str inherited property readonly

Gets the display name for this block. This will be used as identifier when searching for a block.

Returns:

Type Description
str

If block is defined in a ConduitCategory then this will return the category name which is joined with dot (CATEGORY).(BLOCK), otherwise it will just return the block name (BLOCK).

is_coroutine: bool inherited property readonly

Returns True if the inner function is coroutine / async.

Returns:

Type Description
bool

True if the inner function is coroutine (defined with async def syntax), otherwise False.

parameters: Dict[str, inspect.Parameter] inherited property readonly

Returns a dictionary that contains parameters of inner function.

Returns:

Type Description
Dict[str, inspect.Parameter]

A dictionary of function parameters.

raw_function: Union[NoneType, Callable, Coroutine] inherited property readonly

Returns the same raw function that provided when creating the ConduitBlock.

If pydantic is installed, this will return the function without pydantic validation. If pydantic is not installed, this is same as function attribute.

Returns:

Type Description
Union[NoneType, Callable, Coroutine]

Returns the unwrapped raw function.

return_type: Any inherited property readonly

Returns the return type / annotation of the function.

Returns:

Type Description
Any

Any

__init__(self, name, category=None) special

Parameters:

Name Type Description Default
name str

A custom name for the block.

required
category Optional[str]

Name of the category for the block. It can point to a non-existing category.

None