Skip to content

Async multi-part form data #2420

Closed
Closed
@ShantanuNair

Description

@ShantanuNair

I'm using the AsyncApi and am trying to send a multi-part form file. It works locally when running the built docker image, but 404s on the cluster. In the logs I see

error | invalid response from user container; got status code 404, expected status code 200
errorVerbose | invalid response from user container; got status code 404, expected status code 200%!v(PANIC=Format method: runtime error: invalid memory address or nil pointer dereference)

My request:

curl -X POST -F file=@small.wav http://xxx-xxx.elb.us-east-1.amazonaws.com/diarizer

And, in my predictor, I parse it like:

@app.route("/", methods=["POST"])
def prediction():
    file = request.files['file']
    print("Predicting for received file: ", file.filename)

Is this not supported? how do I pass in a file payload to the AsyncAPI?

Related: #1959

Metadata

Metadata

Assignees

No one assigned

    Labels

    questionFurther information is requested

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions