shrinerb / shrine

File Attachment toolkit for Ruby applications
https://shrinerb.com
MIT License
3.18k stars 275 forks source link

Checksum Implementation #555

Closed tke578 closed 3 years ago

tke578 commented 3 years ago

I don't see any checksum javascript implementation following this guide? https://shrinerb.com/docs/direct-s3#checksums

janko commented 3 years ago

I seem to have removed that wiki guide before, I don't remember why exactly, it was probably outdated and didn't work. Anyway, I've added it back now, it should at least give people a starting point – https://github.com/shrinerb/shrine/wiki/Using-Checksums-in-Direct-Uploads

tke578 commented 3 years ago

Thanks @janko! Also, while following thedirect S3 guide with the checksum implementation(PUT request), the uppy file response from uppy does not contain a file.meta['key'] Is that wrong?

benkoshy commented 3 years ago

It's difficult to debug your particular issue without seeing more code. I am using (a slightly modified) version of the code in the s3 guide and it is working successfully. If you could provide a reproducible code sample, or even a snippet, that would help inordinately: or alternatively, the following should be helpful to you: https://github.com/erikdahlstrand/shrine-rails-example - it is a sample rails application.

lastly, may i recommend posting to the forum - for two reasons: (i) the maintainers prefer it, and (ii) you'll get more people viewing your problem and willing to help out.

Thanks @janko! Also, while following thedirect S3 guide with the checksum implementation(PUT request), the uppy file response from uppy does not contain a file.meta['key'] Is that wrong?