CatalogueOfLife / checklistbank

UI for checklistbank.org
https://www.checklistbank.org/
7 stars 2 forks source link

Cannot upload TSV file to bulk matching #1349

Closed mdoering closed 8 months ago

mdoering commented 8 months ago

Who uploading a TSV file with the .tsv file suffix the API responds with a 503. I presume a wrong content type is send? When renaming the file to .txt it all works.

mdoering commented 8 months ago

Example observations_20230525_1305xx.tsv.zip

thomasstjerne commented 8 months ago

I think the API should actually accept text/tab-separated-values for .tsv: https://mimetype.io/text/tab-separated-values

The UI does not actively handle mime types - it just sends what the file system says.

If it is tedious for the backend, I can surely do an exception and explicitly change mime type for .tsv

mdoering commented 8 months ago

Easy to add, will do that. Do you know where exactly it is decided what mime type is send? There are so many for most types, even for json and especially for zip and compression

mdoering commented 8 months ago

CSV is interesting too, text/comma-separated-values is deprecated https://mimetype.io/text/csv