Bug #13527
closedundefined method `each' for nil:NilClass error updating resource with API GET response
Description
Editing an organization via API that includes the param 'users' causes an error like this
| /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/protected_attributes-1.1.3/lib/active_record/mass_assignment_security/persistence.rb:63:in `update' | /home/vagrant/code/foreman-tasks/app/models/foreman_tasks/concerns/action_triggering.rb:38:in `block in update_attributes' | /home/vagrant/code/foreman-tasks/app/models/foreman_tasks/concerns/action_triggering.rb:110:in `dynflow_task_wrap' | /home/vagrant/code/foreman-tasks/app/models/foreman_tasks/concerns/action_triggering.rb:38:in `update_attributes' | /home/vagrant/code/foreman/app/controllers/concerns/api/v2/taxonomies_controller.rb:70:in `update' | /home/vagrant/code/katello/app/controllers/katello/api/v2/organizations_controller.rb:68:in `update'
Removing from attr_accessible allows things to work, though I cannot say what the implications of this removal is.
Updated by Dominic Cleal over 8 years ago
- Status changed from New to Need more information
The description is missing the error you're getting, it only shows part of a stack trace. Please show the whole error and request?
"users" is also not a documented parameter (http://theforeman.org/api/1.10/apidoc/v2/organizations/create.html).
Updated by Shlomi Zadok over 8 years ago
You could send an array of user_ids (documented) and it seems to work quite well, so not a bug I'd say
Updated by Thomas McKay over 8 years ago
Agreed, undocumented. If a call includes 'users' then things blow up. I believe that API calls pull out just the parameters that are attr_accessible to pass to update, is that correct? The question that I have is why is 'users' included in the list of attr_accessible?
Updated by Thomas McKay over 8 years ago
- Status changed from Need more information to New
The source of the 'users' in the PUT is because the GET is returning that as one of the fields1. GET of the json, modification of a portion, then PUT will see this error.
[1] https://github.com/theforeman/foreman/blob/develop/app/views/api/v2/taxonomies/show.json.rabl#L9
Updated by Thomas McKay over 8 years ago
2016-02-03T14:41:48 [app] [W] Action failed | NoMethodError: undefined method `each' for nil:NilClass | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activerecord-4.1.5/lib/active_record/associations/collection_association.rb:356:in `replace' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activerecord-4.1.5/lib/active_record/associations/collection_association.rb:41:in `writer' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activerecord-4.1.5/lib/active_record/associations/builder/association.rb:118:in `users=' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activerecord-4.1.5/lib/active_record/attribute_assignment.rb:45:in `public_send' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activerecord-4.1.5/lib/active_record/attribute_assignment.rb:45:in `_assign_attribute' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/protected_attributes-1.1.3/lib/active_record/mass_assignment_security/attribute_assignment.rb:67:in `block in assign_attributes' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/protected_attributes-1.1.3/lib/active_record/mass_assignment_security/attribute_assignment.rb:61:in `each' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/protected_attributes-1.1.3/lib/active_record/mass_assignment_security/attribute_assignment.rb:61:in `assign_attributes' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/protected_attributes-1.1.3/lib/active_record/mass_assignment_security/persistence.rb:64:in `block in update' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activerecord-4.1.5/lib/active_record/transactions.rb:329:in `block in with_transaction_returning_status' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activerecord-4.1.5/lib/active_record/connection_adapters/abstract/database_statements.rb:201:in `block in transaction' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activerecord-4.1.5/lib/active_record/connection_adapters/abstract/database_statements.rb:209:in `within_new_transaction' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activerecord-4.1.5/lib/active_record/connection_adapters/abstract/database_statements.rb:201:in `transaction' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activerecord-4.1.5/lib/active_record/transactions.rb:208:in `transaction' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activerecord-4.1.5/lib/active_record/transactions.rb:326:in `with_transaction_returning_status' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/protected_attributes-1.1.3/lib/active_record/mass_assignment_security/persistence.rb:63:in `update' | /home/vagrant/code/foreman-tasks/app/models/foreman_tasks/concerns/action_triggering.rb:38:in `block in update_attributes' | /home/vagrant/code/foreman-tasks/app/models/foreman_tasks/concerns/action_triggering.rb:110:in `dynflow_task_wrap' | /home/vagrant/code/foreman-tasks/app/models/foreman_tasks/concerns/action_triggering.rb:38:in `update_attributes' | /home/vagrant/code/foreman/app/controllers/concerns/api/v2/taxonomies_controller.rb:70:in `update' | /home/vagrant/code/katello/app/controllers/katello/api/v2/organizations_controller.rb:68:in `update' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/actionpack-4.1.5/lib/action_controller/metal/implicit_render.rb:4:in `send_action' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/actionpack-4.1.5/lib/abstract_controller/base.rb:189:in `process_action' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/actionpack-4.1.5/lib/action_controller/metal/rendering.rb:10:in `process_action' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/actionpack-4.1.5/lib/abstract_controller/callbacks.rb:20:in `block in process_action' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:113:in `call' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:113:in `call' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:149:in `block in halting_and_conditional' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:149:in `call' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:149:in `block in halting_and_conditional' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:149:in `call' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:149:in `block in halting_and_conditional' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:166:in `call' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:166:in `block in halting' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:149:in `call' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:149:in `block in halting_and_conditional' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:299:in `call' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:299:in `block (2 levels) in halting' | /home/vagrant/code/foreman/app/controllers/api/v2/base_controller.rb:152:in `disable_json_root' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:424:in `block in make_lambda' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:298:in `call' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:298:in `block in halting' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:166:in `call' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:166:in `block in halting' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:149:in `call' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:149:in `block in halting_and_conditional' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:229:in `call' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:229:in `block in halting' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:299:in `call' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:299:in `block (2 levels) in halting' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/rails-observers-0.1.2/lib/rails/observers/action_controller/caching/sweeping.rb:73:in `around' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:447:in `public_send' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:447:in `block in make_lambda' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:298:in `call' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:298:in `block in halting' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:299:in `call' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:299:in `block (2 levels) in halting' | /home/vagrant/code/foreman/app/controllers/concerns/application_shared.rb:13:in `set_timezone' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:424:in `block in make_lambda' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:298:in `call' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:298:in `block in halting' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:166:in `call' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:166:in `block in halting' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:166:in `call' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:166:in `block in halting' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:166:in `call' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:166:in `block in halting' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:166:in `call' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:166:in `block in halting' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:166:in `call' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:166:in `block in halting' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:166:in `call' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:166:in `block in halting' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:149:in `call' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:149:in `block in halting_and_conditional' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:229:in `call' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:229:in `block in halting' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:299:in `call' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:299:in `block (2 levels) in halting' | /home/vagrant/code/foreman/app/models/concerns/foreman/thread_session.rb:32:in `clear_thread' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:424:in `block in make_lambda' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:298:in `call' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:298:in `block in halting' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:229:in `call' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:229:in `block in halting' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:166:in `call' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:166:in `block in halting' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:166:in `call' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:166:in `block in halting' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:166:in `call' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:166:in `block in halting' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:299:in `call' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:299:in `block (2 levels) in halting' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/rails-observers-0.1.2/lib/rails/observers/action_controller/caching/sweeping.rb:73:in `around' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:447:in `public_send' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:447:in `block in make_lambda' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:298:in `call' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:298:in `block in halting' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:149:in `call' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:149:in `block in halting_and_conditional' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:86:in `call' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:86:in `run_callbacks' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/actionpack-4.1.5/lib/abstract_controller/callbacks.rb:19:in `process_action' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/actionpack-4.1.5/lib/action_controller/metal/rescue.rb:29:in `process_action' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/actionpack-4.1.5/lib/action_controller/metal/instrumentation.rb:31:in `block in process_action' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activesupport-4.1.5/lib/active_support/notifications.rb:159:in `block in instrument' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activesupport-4.1.5/lib/active_support/notifications/instrumenter.rb:20:in `instrument' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activesupport-4.1.5/lib/active_support/notifications.rb:159:in `instrument' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/actionpack-4.1.5/lib/action_controller/metal/instrumentation.rb:30:in `process_action' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/actionpack-4.1.5/lib/action_controller/metal/params_wrapper.rb:250:in `process_action' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activerecord-4.1.5/lib/active_record/railties/controller_runtime.rb:18:in `process_action' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/actionpack-4.1.5/lib/abstract_controller/base.rb:136:in `process' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/actionview-4.1.5/lib/action_view/rendering.rb:30:in `process' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/actionpack-4.1.5/lib/action_controller/metal.rb:196:in `dispatch' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/actionpack-4.1.5/lib/action_controller/metal/rack_delegation.rb:13:in `dispatch' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/actionpack-4.1.5/lib/action_controller/metal.rb:232:in `block in action' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/actionpack-4.1.5/lib/action_dispatch/routing/route_set.rb:82:in `call' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/actionpack-4.1.5/lib/action_dispatch/routing/route_set.rb:82:in `dispatch' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/actionpack-4.1.5/lib/action_dispatch/routing/route_set.rb:50:in `call' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/actionpack-4.1.5/lib/action_dispatch/routing/mapper.rb:45:in `call' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/actionpack-4.1.5/lib/action_dispatch/journey/router.rb:71:in `block in call' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/actionpack-4.1.5/lib/action_dispatch/journey/router.rb:59:in `each' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/actionpack-4.1.5/lib/action_dispatch/journey/router.rb:59:in `call' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/actionpack-4.1.5/lib/action_dispatch/routing/route_set.rb:678:in `call' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/railties-4.1.5/lib/rails/engine.rb:514:in `call' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/railties-4.1.5/lib/rails/railtie.rb:194:in `public_send' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/railties-4.1.5/lib/rails/railtie.rb:194:in `method_missing' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/actionpack-4.1.5/lib/action_dispatch/journey/router.rb:71:in `block in call' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/actionpack-4.1.5/lib/action_dispatch/journey/router.rb:59:in `each' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/actionpack-4.1.5/lib/action_dispatch/journey/router.rb:59:in `call' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/actionpack-4.1.5/lib/action_dispatch/routing/route_set.rb:678:in `call' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/actionpack-4.1.5/lib/action_dispatch/middleware/static.rb:64:in `call' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/actionpack-4.1.5/lib/action_dispatch/middleware/static.rb:64:in `call' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/actionpack-4.1.5/lib/action_dispatch/middleware/static.rb:64:in `call' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/apipie-rails-0.3.5/lib/apipie/static_dispatcher.rb:65:in `call' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/bullet-5.0.0/lib/bullet/rack.rb:12:in `call' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/apipie-rails-0.3.5/lib/apipie/extractor/recorder.rb:132:in `call' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/apipie-rails-0.3.5/lib/apipie/middleware/checksum_in_headers.rb:27:in `call' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/rack-openid-1.4.2/lib/rack/openid.rb:98:in `call' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/rack-1.5.5/lib/rack/etag.rb:23:in `call' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/rack-1.5.5/lib/rack/conditionalget.rb:35:in `call' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/rack-1.5.5/lib/rack/head.rb:11:in `call' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/actionpack-4.1.5/lib/action_dispatch/middleware/params_parser.rb:27:in `call' | /home/vagrant/code/foreman/lib/middleware/catch_json_parse_errors.rb:9:in `call' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/actionpack-4.1.5/lib/action_dispatch/middleware/flash.rb:254:in `call' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/rack-1.5.5/lib/rack/session/abstract/id.rb:225:in `context' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/rack-1.5.5/lib/rack/session/abstract/id.rb:220:in `call' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/actionpack-4.1.5/lib/action_dispatch/middleware/cookies.rb:560:in `call' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activerecord-4.1.5/lib/active_record/query_cache.rb:36:in `call' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activerecord-4.1.5/lib/active_record/connection_adapters/abstract/connection_pool.rb:621:in `call' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activerecord-4.1.5/lib/active_record/migration.rb:380:in `call' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/actionpack-4.1.5/lib/action_dispatch/middleware/callbacks.rb:29:in `block in call' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:82:in `run_callbacks' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/actionpack-4.1.5/lib/action_dispatch/middleware/callbacks.rb:27:in `call' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/actionpack-4.1.5/lib/action_dispatch/middleware/reloader.rb:73:in `call' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/actionpack-4.1.5/lib/action_dispatch/middleware/remote_ip.rb:76:in `call' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/actionpack-4.1.5/lib/action_dispatch/middleware/debug_exceptions.rb:17:in `call' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/actionpack-4.1.5/lib/action_dispatch/middleware/show_exceptions.rb:30:in `call' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/railties-4.1.5/lib/rails/rack/logger.rb:38:in `call_app' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/railties-4.1.5/lib/rails/rack/logger.rb:22:in `call' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/quiet_assets-1.1.0/lib/quiet_assets.rb:27:in `call_with_quiet_assets' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/actionpack-4.1.5/lib/action_dispatch/middleware/request_id.rb:21:in `call' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/rack-1.5.5/lib/rack/methodoverride.rb:21:in `call' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/rack-1.5.5/lib/rack/runtime.rb:17:in `call' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/activesupport-4.1.5/lib/active_support/cache/strategy/local_cache_middleware.rb:26:in `call' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/rack-1.5.5/lib/rack/lock.rb:17:in `call' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/actionpack-4.1.5/lib/action_dispatch/middleware/static.rb:64:in `call' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/rack-1.5.5/lib/rack/sendfile.rb:112:in `call' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/railties-4.1.5/lib/rails/engine.rb:514:in `call' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/railties-4.1.5/lib/rails/application.rb:144:in `call' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/railties-4.1.5/lib/rails/railtie.rb:194:in `public_send' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/railties-4.1.5/lib/rails/railtie.rb:194:in `method_missing' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/rack-1.5.5/lib/rack/urlmap.rb:65:in `block in call' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/rack-1.5.5/lib/rack/urlmap.rb:50:in `each' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/rack-1.5.5/lib/rack/urlmap.rb:50:in `call' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/rack-1.5.5/lib/rack/builder.rb:138:in `call' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/rack-1.5.5/lib/rack/urlmap.rb:65:in `block in call' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/rack-1.5.5/lib/rack/urlmap.rb:50:in `each' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/rack-1.5.5/lib/rack/urlmap.rb:50:in `call' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/rack-1.5.5/lib/rack/content_length.rb:14:in `call' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/puma-2.16.0/lib/puma/server.rb:557:in `handle_request' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/puma-2.16.0/lib/puma/server.rb:404:in `process_client' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/puma-2.16.0/lib/puma/server.rb:270:in `block in run' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/puma-2.16.0/lib/puma/thread_pool.rb:106:in `call' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/puma-2.16.0/lib/puma/thread_pool.rb:106:in `block in spawn_thread' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/logging-2.0.0/lib/logging/diagnostic_context.rb:448:in `call' | /home/vagrant/.rvm/gems/ruby-1.9.3-p448/gems/logging-2.0.0/lib/logging/diagnostic_context.rb:448:in `block in create_with_logging_context' 2016-02-03T14:41:48 [app] [I] Rendered api/v2/errors/standard_error.json.rabl within api/v2/layouts/error_layout (2.0ms)
Updated by Dominic Cleal over 8 years ago
- Subject changed from 'users' should not be listed in models/taxonomy.rb attr_accessible to undefined method `each' for nil:NilClass error updating resource with API GET response
- Priority changed from High to Normal
The question that I have is why is 'users' included in the list of attr_accessible?
UI use, not API.
Updated by The Foreman Bot over 8 years ago
- Status changed from New to Ready For Testing
- Assignee set to Thomas McKay
- Pull request https://github.com/theforeman/foreman/pull/3188 added
Updated by Thomas McKay over 8 years ago
- Status changed from Ready For Testing to Rejected
not a bug