Open laptite opened 9 years ago
I faced with this issue too with Ruby on Rails 4.2.3, Ruby 2.2.2, Paperclip 4.3.0, and Paperclip-meta 1.2.0. @laptite your solution helps, thank you.
Can we start with a failing test to reproduce this?
I'm sure this is a conflict with metadata from paperclip-av-transcoder gem, see https://github.com/ruby-av/paperclip-av-transcoder#meta-data
Scenario:
The existing meta, or
original = instance.send("#{name}_meta")
is returning a hash in a string format e.g."{:length=>\"0:00:25.54\", :fps=>30, :size=>\"1920x1200\", :aspect=>1.6}"
. The TypeError exception is being thrown when Marshal.load can't make sense of the string returned by this callBase64.decode64(meta)
The below fix allows the video to be processed and returns the expected output when calling width or height on the uploaded video. Not saying it's ideal but it works for now.
Full Backtrace: