From d6830e59177048ee628e47352cfe86036f1b0374 Mon Sep 17 00:00:00 2001 From: Carlos Sevilla Salcedo <22427519+sevisal@users.noreply.github.com> Date: Wed, 29 Nov 2023 14:29:05 +0100 Subject: [PATCH] Fix default option display (#119) --- src/vai_lab/utils/plugins/pluginCanvas.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/vai_lab/utils/plugins/pluginCanvas.py b/src/vai_lab/utils/plugins/pluginCanvas.py index 3695c61d..f1e88540 100644 --- a/src/vai_lab/utils/plugins/pluginCanvas.py +++ b/src/vai_lab/utils/plugins/pluginCanvas.py @@ -5,7 +5,7 @@ import os import numpy as np import pandas as pd -from inspect import getmembers, isfunction, ismethod, signature, _empty +from inspect import getmembers, isfunction, ismethod, signature from functools import reduce from typing import Dict, List @@ -639,9 +639,9 @@ def getArgs(self, f): :returns out: two dictionaries with arguments and default value (if optional) """ - meth_req = {name: param.default for name, param in signature(f).parameters.items() if param.default is _empty} + meth_req = {name: '' for name, param in signature(f).parameters.items() if param.default is param.empty} meth_req.pop('self', None) - meth_r_opt = {name: param.default for name, param in signature(f).parameters.items() if param.default is not _empty} + meth_r_opt = {name: param.default for name, param in signature(f).parameters.items() if param.default is not param.empty} return meth_req, meth_r_opt def addMeth(self):