curationexperts / trove

Digital Image Library based on Tufts repository models
0 stars 2 forks source link

Duplicate collection folder created #207

Closed amrri06 closed 9 years ago

amrri06 commented 9 years ago

A new course collection, "Works on Paper" was created. I clicked on Watercolor paintings -- Asia under subject and added images to the collection folder via drag and drop. I clicked on search to get a list of more images to add to the newly created collection folder and two folders with the title "Works on Paper," appeared in the search result. One folder (uc:79) opens as expected, showing images within. When clicking on the other folder (uc.78) we get the error message "We're sorry, but something went wrong" error message. We were not able to reproduce this issue.

Mike Korcynski saw the following server error messages:

The error on the server is:

Started GET "/course_collections/tufts.uc:78" for 10.250.108.11 at 2014-11-03 16:59:18 -0500 Processing by CourseCollectionsController#show as HTML Parameters: {"id"=>"tufts.uc:78"} User Load (0.7ms) SELECT users.* FROM users WHERE users.id = 1 ORDER BY users.id ASC LIMIT 1 Role Load (0.8ms) SELECT roles.* FROM roles INNER JOIN roles_users ON roles.id = roles_users.role_id WHERE roles_users.user_id = 1 Usergroups are ["public", "admin", "registered"] Role Exists (0.4ms) SELECT 1 AS one FROM roles INNER JOIN roles_users ON roles.id = roles_users.role_id WHERE roles_users.user_id = 1 AND roles.name = 'admin' LIMIT 1 Completed 500 Internal Server Error in 136ms

NoMethodError (undefined method ancestors_and_self' for nil:NilClass): app/controllers/curated_collections_controller.rb:67:inblock (2 levels) in show' app/controllers/curated_collections_controller.rb:65:in `show'

In rails console using that object the error looks like this:

2.1.2 :006 > course_collection = CourseCollection.find('tufts.uc:78') => #<CourseCollection pid: "tufts.uc:78", creator: "ccavalie", description: [""], date_created: [], title: "Works on paper", createdby: "tdil", displays: ["tdil"]> 2.1.2 :007 > course_collection.ancestors_and_self NoMethodError: undefined method ancestors_and_self' for nil:NilClass from /home/hydradm/.rvm/gems/ruby-2.1.2@tdil/bundler/gems/tufts_models-8bb0b0f07 891/app/models/concerns/with_parent.rb:12:inancestors_and_self' from (irb):7

acozine commented 9 years ago

Cannot reproduce. Closing for now; if the behavior recurs, we can open a new ticket.