Unstructured-IO / unstructured-api

Apache License 2.0
508 stars 108 forks source link

Using Swagger endpoint results in `Expecting value: line 1 column 1 (char 0)` #343

Closed awalker4 closed 7 months ago

awalker4 commented 8 months ago

Describe the bug A user testing out the endpoint at https://api.unstructured.io/general/docs#/default/pipeline_1_general_v0_general_post hit this. Enter your api key and upload a file, the result is a 500 error.

To Reproduce The issue is that we're sending empty values for everything, and extract_image_block_types doesn't like an empty string.

To fix, we should handle empty strings for this param. Bonus points if we can find a way to remove the "send empty string" defaults in Swagger. Is there a way to configure this in FastAPI? Screenshot 2024-01-19 at 11 51 31 AM

awalker4 commented 8 months ago

Hi @christinestraub can you take a look at this?

awalker4 commented 7 months ago

Confirmed that this was fixed by #359