From 75452fb758101f21259865ae48fed2e0f733f116 Mon Sep 17 00:00:00 2001 From: gustavoschaedler Date: Fri, 14 Jul 2023 05:08:12 +0100 Subject: [PATCH] =?UTF-8?q?=F0=9F=94=A7=20refactor(custom=5Fcomponent.py):?= =?UTF-8?q?=20make=20'code'=20attribute=20optional=20in=20CustomComponent?= =?UTF-8?q?=20class=20to=20allow=20instances=20without=20explicit=20code?= =?UTF-8?q?=20value?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/backend/langflow/interface/custom/custom_component.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/backend/langflow/interface/custom/custom_component.py b/src/backend/langflow/interface/custom/custom_component.py index 5a9ddecbb..8fb5af62c 100644 --- a/src/backend/langflow/interface/custom/custom_component.py +++ b/src/backend/langflow/interface/custom/custom_component.py @@ -8,7 +8,7 @@ from langflow.utils import validate class CustomComponent(Component): - code: str + code: Optional[str] field_config: dict = {} code_class_base_inheritance = "CustomComponent" function_entrypoint_name = "build"