I try to download an MP3 file (using the paperclip plugin) and then immediately read the MP3 information (using Mp3 Mp3) to get the title, song length, etc.
I can successfully download the MP3 file using paperclip, but when I try Mp3Info.open (@ song.music.url), I get an error when the file is empty. Is there a correct file link so that Mp3Info can find the file?
(Note that the actual file is located in /public/system/musics/:id/original/:filename.extention)
ActionView::TemplateError (empty file) on line
5: <% Mp3Info.open( @song.music.url ) do |mp3| %>
6: <% mp3.tag.title %>
7: <% end %>
source
share