Here's the Webrick run. (The Phusion with silencers removed follows.)
Processing MerchantSubcategoryController#create (for 127.0.0.1 at
2011-01-12 19:10:30) [POST]
Parameters: {"commit"=>"Create", "associated_id"=>"18",
"record"=>{"name"=>"Test ZZZ", "merchant_category"=>{"name"=>"Shopping
& Retail", "id"=>"18"}}}
State Load (0.2ms) SELECT `states`.id FROM `states` WHERE
(`states`.`id` IS NULL) LIMIT 1
SQL (0.1ms) BEGIN
SQL (0.1ms) ROLLBACK
NoMethodError (You have a nil object when you didn't expect it!
You might have expected an instance of Array.
The error occurred while evaluating nil.empty?):
Rendered rescues/_trace (127.5ms)
Rendered rescues/_request_and_response (0.4ms)
Rendering rescues/layout (internal_server_error)
One odd thing I note, that it does a SQL query for the state table.
Those are states of the US (OR, CA, WA), not program states. There's
no association between the categories & states, so I'm baffled as to
why it would call those up. And why would it seek those with a null
Id? Wouldn't it want those with a non-null Id? Weird. (Again, this
is ActiveScaffold doing this, not my code.)
On Jan 12, 2:43 am, "Sergio Cambra .:: entreCables S.L. ::."
<[email protected]> wrote:
> On Miércoles, 12 de Enero de 2011 06:23:39 dlamet escribió:
>
> > I'm using ActiveScaffold to manage some merchant categories. The
> > merchant & category objects are pretty plain-vanilla. When I try to
> > create a new one, I get this error. It doesn't make it into either
> > ActiveScaffold code, nor my own code. Any suggestions?
>
> Do you get that error with webrick (script/server)? Anyway, backtrace is not
> full, try to remove backtrace silencers to get right line of error
>
>
>
>
>
> > NoMethodError (You have a nil object when you didn't expect it!
> > You might have expected an instance of Array.
> > The error occurred while evaluating nil.empty?):
> > passenger (2.2.15) lib/phusion_passenger/rack/request_handler.rb:
> > 92:in `process_request'
> > passenger (2.2.15) lib/phusion_passenger/abstract_request_handler.rb:
> > 207:in `main_loop'
> > passenger (2.2.15) lib/phusion_passenger/railz/
> > application_spawner.rb:441:in `start_request_handler'
> > passenger (2.2.15) lib/phusion_passenger/railz/
> > application_spawner.rb:381:in `handle_spawn_application'
> > passenger (2.2.15) lib/phusion_passenger/utils.rb:252:in `safe_fork'
> > passenger (2.2.15) lib/phusion_passenger/railz/
> > application_spawner.rb:377:in `handle_spawn_application'
> > passenger (2.2.15) lib/phusion_passenger/abstract_server.rb:352:in
> > `__send__'
> > passenger (2.2.15) lib/phusion_passenger/abstract_server.rb:352:in
> > `main_loop'
> > passenger (2.2.15) lib/phusion_passenger/abstract_server.rb:196:in
> > `start_synchronously'
> > passenger (2.2.15) lib/phusion_passenger/abstract_server.rb:163:in
> > `start'
> > passenger (2.2.15) lib/phusion_passenger/railz/
> > application_spawner.rb:222:in `start'
> > passenger (2.2.15) lib/phusion_passenger/spawn_manager.rb:253:in
> > `spawn_rails_application'
> > passenger (2.2.15) lib/phusion_passenger/
> > abstract_server_collection.rb:126:in `lookup_or_add'
> > passenger (2.2.15) lib/phusion_passenger/spawn_manager.rb:247:in
> > `spawn_rails_application'
> > passenger (2.2.15) lib/phusion_passenger/
> > abstract_server_collection.rb:80:in `synchronize'
> > passenger (2.2.15) lib/phusion_passenger/
> > abstract_server_collection.rb:79:in `synchronize'
> > passenger (2.2.15) lib/phusion_passenger/spawn_manager.rb:246:in
> > `spawn_rails_application'
> > passenger (2.2.15) lib/phusion_passenger/spawn_manager.rb:145:in
> > `spawn_application'
> > passenger (2.2.15) lib/phusion_passenger/spawn_manager.rb:278:in
> > `handle_spawn_application'
> > passenger (2.2.15) lib/phusion_passenger/abstract_server.rb:352:in
> > `__send__'
> > passenger (2.2.15) lib/phusion_passenger/abstract_server.rb:352:in
> > `main_loop'
> > passenger (2.2.15) lib/phusion_passenger/abstract_server.rb:196:in
> > `start_synchronously'
>
> --
> Sergio Cambra .:: entreCables S.L. ::.
> Mariana Pineda 23, 50.018 Zaragoza
> T) 902 021 404 F) 976 52 98 07 E) [email protected]
--
You received this message because you are subscribed to the Google Groups
"ActiveScaffold : Ruby on Rails plugin" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/activescaffold?hl=en.