ResearchObject / ro-crate-inveniordm

RO-Crate uploader for InvenioRDM
MIT License
2 stars 1 forks source link

Some file uploads time out with 504 error - possibly encoding issue #22

Closed elichad closed 2 months ago

elichad commented 2 months ago

When uploading a file with this content:

"Date","Minimum temperature (°C)","Maximum temperature (°C)","Rainfall (mm)"
2022-02-01,16.0,28.4,0.6
2022-02-02,16.3,17.2,12.4

The server returns a 504 error. Other files (including the test files in this repository) work fine, so it does not appear to be a server-side problem.

Removing the ° symbol made the upload succeed, so I believe this is to do with using "Content-Type": "application/octet-stream" in our headers and not adapting to the encoding of the individual files.

elichad commented 2 months ago

According to this example https://github.com/inveniosoftware/docs-invenio-rdm-restapi-example, all files to upload should be opened in "rb" mode