Forum: Ruby on Rails Updating with Paperclip

Announcement (2017-05-07): is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see and for other Rails- und Ruby-related community platforms.
David (Guest)
on 2009-02-06 09:12
(Received via mailing list)
I cannot seem to get paperclip working for my file uploads after
switching from attachment_fu.  I have the correct fields migrated into
the database, have included   has_attached_file :photo, :styles =>
{ :thumb => "175x175>" } in my mode, but no photo is ever saved in the
database and there are no errors.  Looking in the console I noticed
that it says paperclip is "Saving files for photo" and then on the
next line "Deleting files for photo".  Im wondering if this is a clue
to my problem?  The surrounding output is below:

Processing SpecController#update (for at 2009-02-05
23:05:11) [PUT]
  Session ID:
  Parameters: {"commit"=>"Upload",
"_method"=>"put", "action"=>"update", "spec"=>{"photo"=>"Blue-Wild-
Flower-1-1024x768.jpg"}, "id"=>"10", "controller"=>"spec"}
  User Columns (0.006779)   SHOW FIELDS FROM `users`
  User Load (0.028061)   SELECT * FROM `users` WHERE (`users`.`id` =
  CACHE (0.000000)   SELECT * FROM `users` WHERE (`users`.`id` = 2)
  Spec Load (0.000263)   SELECT * FROM `specs` WHERE (`specs`.user_id
= 2) LIMIT 1
  Spec Columns (0.002173)   SHOW FIELDS FROM `specs`
[paperclip] Paperclip attachment photo on Spec initialized.
  SQL (0.001320)   BEGIN
[paperclip] Saving attachments.
[paperclip] Saving files for photo
[paperclip] Deleting files for photo
[paperclip] Writing files for photo
  SQL (0.000070)   COMMIT
  CACHE (0.000000)   SELECT * FROM `users` WHERE (`users`.`id` = 2)
Completed in 0.06918 (14 reqs/sec) | Rendering: 0.00947 (13%) | DB:
0.03867 (55%) | 200 OK [http://localhost/spec/10]

This is my controller action(for testing):

 def update
    @spec = logged_in_user.spec ||

Anyone have any ideas, this is driving me crazy.
This topic is locked and can not be replied to.