Refactor code_parser.py to remove kwargs from
showing up as fields in the frontend
This commit is contained in:
parent
831f665e06
commit
d2966c37df
1 changed files with 5 additions and 3 deletions
|
|
@ -6,8 +6,8 @@ from typing import Any, Dict, List, Type, Union
|
||||||
|
|
||||||
from cachetools import TTLCache, cachedmethod, keys
|
from cachetools import TTLCache, cachedmethod, keys
|
||||||
from fastapi import HTTPException
|
from fastapi import HTTPException
|
||||||
|
from langflow.interface.custom.schema import (CallableCodeDetails,
|
||||||
from langflow.interface.custom.schema import CallableCodeDetails, ClassCodeDetails
|
ClassCodeDetails)
|
||||||
|
|
||||||
|
|
||||||
class CodeSyntaxError(HTTPException):
|
class CodeSyntaxError(HTTPException):
|
||||||
|
|
@ -168,7 +168,9 @@ class CodeParser:
|
||||||
args += self.parse_positional_args(node)
|
args += self.parse_positional_args(node)
|
||||||
args += self.parse_varargs(node)
|
args += self.parse_varargs(node)
|
||||||
args += self.parse_keyword_args(node)
|
args += self.parse_keyword_args(node)
|
||||||
args += self.parse_kwargs(node)
|
# Commented out because we don't want kwargs
|
||||||
|
# showing up as fields in the frontend
|
||||||
|
# args += self.parse_kwargs(node)
|
||||||
|
|
||||||
return args
|
return args
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue