Shrine v2.7.0 Release Notes

Release Date: 2017-09-11 // over 6 years ago
    • ๐Ÿ—„ Deprecate the Shrine::DownloadEndpoint constant over Shrine.download_endpoint (@janko)

    • ๐Ÿ‘ Allow an additional #headers attribute on presigns and return it in presign_endpoint (@janko)

    • Allow overriding upload_endpoint and presign_endpoint options per-endpoint (@janko)

    • Add :presign and :rack_response options to presign_endpoint (@janko)

    • Add :upload, :upload_context and :rack_response options to upload_endpoint (@janko)

    • Modify upload_endpoint and presign_endpoint to return text/plain error responses (@janko)

    • โž• Add :request upload context parameter in upload_endpoint (@janko)

    • ๐Ÿ”„ Change :action upload context parameter to :upload in upload_endpoint (@janko)

    • Return 405 Method Not Allowed on invalid HTTP verb in upload_endpoint and presign_endpoint (@janko)

    • Modify upload_endpoint and presign_endpoint to handle requests on the root URL (@janko)

    • Allow creating Rack apps dynamically in upload_endpoint and presign_endpoint (@janko)

    • Remove Roda dependency from upload_endpoint and presign_endpoint plugins (@janko)

    • ๐Ÿ”Œ Split direct_upload plugin into upload_endpoint and presign_endpoint plugins (@janko)

    • ๐Ÿ‘Œ Support the new aws-sdk-s3 gem in Shrine::Storage::S3 (@lizdeika)

    • Return Cache-Control header in download_endpoint to permanently cache responses (@janko)

    • Return 404 Not Found when uploaded file doesn't exist in download_endpoint (@janko)

    • ๐Ÿ“‡ Utilize uploaded file metadata when generating response in download_endpoint (@janko)

    • ๐Ÿ›  Fix deprecation warning when generating fake presign with query parameters (@janko)

    • ๐Ÿšฉ Don't raise error in file and filemagic MIME type analyzer on empty IO (@ypresto)

    • ๐Ÿ”Œ Require down in remote_url plugin even when a custom downloader is given (@janko)

    • ๐Ÿ”Œ Require time library in logging plugin to fix undefined method #iso8601 for Time (@janko)

    • ๐Ÿ‘ Allow validations defined on a superclass to be reused in a subclass (@printercu)

    • ๐Ÿ‘ Allow validation error messages to be an array of arguments for ActiveRecord (@janko)

    • ๐Ÿ‘ Allow model subclasses to override the attachment with a different uploader (@janko)

    • Accept Attacher.new options like store: and cache: via Attachment.new (@ypresto)

    • Raise ArgumentError when :bucket option is nil in Shrine::Storage::S3#initialize (@janko)

    • Don't wrap base64-encoded content into 60 columns in UploadedFile#base64 and #data_uri (@janko)

    • Add :mini_mime option to determine_mime_type plugin for using the mini_mime gem (@janko)

    • ๐Ÿ›  Fix data_uri plugin raising an exception on Ruby 2.4.1 when using raw data URIs (@janko)

    • Implement Shrine::Storage::S3#open using the aws-sdk gem instead of Down.open (@janko)

    • ๐Ÿ—„ Un-deprecate Shrine.uploaded_file accepting file data as JSON string (@janko)

    • Don't wrap base64-formatted signatures to 60 columns (@janko)

    • Don't add a newline at the end of the base64-formatted signature (@janko)