How to accept optional parameters
Opened this issue · 0 comments
dashesy commented
I want the endpoint to get 2 keys, 1 being optional. e.g.
@input_schema('b64', StandardPythonParameterType("base64_encoded_image"), convert_to_provided_type=False)
@input_schema('url', StandardPythonParameterType("image url"), convert_to_provided_type=False)
@output_schema(StandardPythonParameterType(output_sample))
def run(b64, url):
pass
I still have to pass both inputs. And if I change this to
@input_schema('b64', StandardPythonParameterType("base64_encoded_image"), convert_to_provided_type=False)
@input_schema('url', StandardPythonParameterType("image url"), convert_to_provided_type=False)
@output_schema(StandardPythonParameterType(output_sample))
def run(b64="", url=""):
pass
Local instance works as expected (Both parameters become optional). But if I deploy to Aci then both parameters will be always empty! They will not get values