-
Notifications
You must be signed in to change notification settings - Fork 45
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
Errno::ENOENT: No such file or directory #9
Comments
I confirmed that ffmpegthumbnailer works when I run the command by itself in the command line: ffmpegthumbnailer -i thumb_Untitled.mov -o tmpfile.png However, it doesn't seem to be working using the thumbnail process outlined in the readme. |
Is this file actually there? |
Looks like it doesn’t find a tmp file in place when it’s going to process it further. |
yes, that's the problem; it says that it successfully runs ffmpegthumbnailer, but it hasn't actually saved the file. |
Hmm.. I’ll try to reproduce it. BTW, is it 100% reproducible on your 2013/9/28 ttseng notifications@github.com
Yours truly, Pavel. |
yes, it's reproducible. do you have some sample code besides what's in the README? I'm using the exact same code that's there, and my app can't seem to save the tmpfile. |
Thanks for the report. I’ll try to make a test app ASAP. 2013/9/29 ttseng notifications@github.com
Yours truly, Pavel. |
BTW what OS are you using to run the app? 2013/9/29 ttseng notifications@github.com
Yours truly, Pavel. |
I'm using OS X 10.8.5 and using Rails 3.2.14 |
I found the issue! It was having problems with my path, which had spaces. Once I got rid of the spaces, it worked correctly! |
When I try running the thumbnailer on my video, I get the error:
Errno::ENOENT: No such file or directory
Here are my logs:
Started POST "/videos" for 127.0.0.1 at 2013-09-27 15:52:34 -0400
Processing by VideosController#create as HTML
Parameters: {"utf8"=>"✓", "authenticity_token"=>"5lMoFtM5Rrdu4Ra8ut8rD3jYv3FJ0cxo38QW5ATw9ZQ=", "video"=>{"project_id"=>"4", "step_id"=>"22", "saved"=>"true", "embed_url"=>"", "video_path"=>#<ActionDispatch::Http::UploadedFile:0x007fc09b974420 @original_filename="2013-08-02 17.19.02.mp4", @content_type="video/mp4", @headers="Content-Disposition: form-data; name="video[video_path]"; filename="2013-08-02 17.19.02.mp4"\r\nContent-Type: video/mp4\r\n", @tempfile=#File:/var/folders/dc/c0nfvwy96lq7p4ll94mklnmr0000gp/T/RackMultipart20130927-20398-qyz4qz>}, "button"=>""}
User Load (0.5ms) SELECT "users".* FROM "users" WHERE "users"."id" = 1 LIMIT 1
Project Load (0.2ms) SELECT "projects".* FROM "projects" WHERE "projects"."id" = $1 LIMIT 1 [["id", "4"]]
Running....ffmpegthumbnailer -i /Users/.../Website/public/uploads/tmp/1380311554-20398-7589/thumb_2013-08-02_17.19.02.mp4 -o /Users/.../Website/public/uploads/tmp/1380311554-20398-7589/tmpfile.png -c png -q 10 -s 158 -f
Success!
Errno::ENOENT: No such file or directory - (/Users/.../Website/public/uploads/tmp/1380311554-20398-7589/tmpfile.png, /Users/.../Website/public/uploads/tmp/1380311554-20398-7589/thumb_2013-08-02_17.19.02.mp4)
This is what my uploader file looks like:
class VideoPathUploader < CarrierWave::Uploader::Base
include CarrierWave::Video
include CarrierWave::Video::Thumbnailer
process encode_video: [:mp4]
Choose what kind of storage to use for this uploader:
storage :fog
Override the directory where uploaded files will be stored.
This is a sensible default for uploaders that are meant to be mounted:
def store_dir
"#{model.class.to_s.underscore}/#{mounted_as}/#{model.id}"
end
version :thumb do
process thumbnail: [{format: 'png', quality: 10, size: 158, strip: true, logger: Rails.logger}]
def full_filename for_file
png_name for_file, version_name
end
end
def png_name for_file, version_name
%Q{#{version_name}_#{for_file.chomp(File.extname(for_file))}.png}
end
end
The text was updated successfully, but these errors were encountered: