Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

content-type wrong when converting specific format #1388

Open
johnvoloski opened this issue May 16, 2014 · 5 comments
Open

content-type wrong when converting specific format #1388

johnvoloski opened this issue May 16, 2014 · 5 comments
Labels

Comments

@johnvoloski
Copy link

CarrierWave 0.8.0
Ruby 1.9.3-p545

# Uploader
process convert: 'png'
process set_content_type: true
uploader = Uploader.new
uploader.image = 'image.jpeg'
uploader.store!

https://github.com/carrierwaveuploader/carrierwave/blob/master/lib/carrierwave/processing/mime_types.rb#L60

Content-type should be based on the new format, but is based on the original image

@timherby
Copy link

I'm also seeing this issue, using:
carrierwave 0.10.0
mini_magick 3.5.0

Any advice?

@FabianOudhaarlem
Copy link

I am also seeing this issue

  • Carrierwave 0.10
  • Carrierwave-video-thumbnailer 0.1.4

@thomasfedb
Copy link
Contributor

@timherby @FabianOudhaarlem could you please provide a minimal reproduction of this issue with carrierwave 0.10.0.

@thomasfedb thomasfedb added the bug label Nov 28, 2015
@timherby
Copy link

Thanks for the follow-up. We actually switched to a different solution using carrierwave only for upload and ImgIx for resizing/formatting. So we no longer need this.

@lostapathy
Copy link

lostapathy commented Jan 12, 2018

I am seeing this using carrierwave 1.2.2 and mini_magick 4.8.0 and then uploading the image to S3 with fog-aws 2.0.0. The image format conversion is successful, but the original (now wrong) mime-type is stored in S3, which causes S3 to serve the file back out with the wrong mime-type.

In our case, we're converting pdf to jpg, and getting those mime-types mixed up is not handled gracefully by the browser. We're working around it with a solution inspired by #617 for now.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

5 participants