similar to: stack level too deep from has_many / belongs_to relationship

Displaying 17 results from an estimated 17 matches similar to: "stack level too deep from has_many / belongs_to relationship"

2007 Sep 18
2
rSpec / Nested Routes / Mocks
I''m having a terrible time trying to test a nested route with rSpec. I can''t seem to tell rSpec to expect the call @item.user. The following error message plagues me not matter how I try to fuss with the mock: Spec::Mocks::MockExpectationError in ''ItemsController handling POST / items should redirect to the new course on successful save'' Mock
2007 Oct 26
3
Specing with Subdomains as Account Keys
How do you go about implementing and rspecing subdomains as account keys? I''m sure that this must be an issues for others as well. So I have an app using subdomains as account keys. The Application Controller sets up @current_company in a before filter. Everything is done within the context of the @current_company. After reading about Demeter''s Revenge
2006 Apr 04
2
HABTM
Hi. Im new to Ruby and new to Ruby on Rails and have problems realizing a =20= simple many_to_many relationship: My tables: items <-> items_users <-> users ------------------------------------------------------------------------=20= -------------------------------------- id user_id = id name item_id name ... = password = ...... My Code: class
2006 May 29
2
Adding model fields
I added a field "url" to a table, modified the view to show the new field. Now I''m getting an error in the code that processes the form in the view: copy_from_item = Item.find(params[:id]) @item = Item.new(copy_from_item.attributes) The second line here gives this error: undefined method `url='' for #<Item:0x246e3f0> RAILS_ROOT:
2011 Jan 03
2
Adding style to model (paperclip)
hello, I have a model (item) with one attachment (photo) and one style (small): class Producto < ActiveRecord::Base has_attached_file :photo, :styles => { :small => "50x50"}, end I would like to add a new style (:large), so I modify item.rb: class Producto < ActiveRecord::Base has_attached_file :photo, :styles => {{ :small => "50x50"},{ :large =>
2006 Jun 21
3
Show Exceptions in Production mode.
Does someone know what to set so that exceptions are shown (to user) when in production mode? I would like the exception to show exactly as it does in development mode. I know that they are written to the log. Richard RogueWaveMarine.com -- Posted with http://DevLists.com. Sign up and save your mailbox.
2006 Apr 17
6
acts_as_taggable confused
Ahoy, So i''ve installed the acts_as_taggable module and everything is fine, but i''m a bit confused about this bit of code described in the API "photo = Photo.new # splits and adds to the tags collection photo.tag "wine beer alcohol" # don''t need to split since it''s an array, but replaces the tags collection # trailing and leading
2010 Jul 14
3
`stack level too deep` when overwriting `to_json`
I''m using [acts_as_commentable_with_threading](http://github.com/elight/acts_as_commentable_with_threading/), and it worked fine until I tried to overwrite the to_json function to include more details about the associated user. Here''s part of the comment class (which was originally defined in the plugin, but I moved it to the models folder, a move which seems not to affect the
2006 Aug 14
0
Automatic helpers for controller modules?
Just wondering, is there a way to automatically include helper modules for controllers in modules? Something like (which doesn''t work, so I use ''helper :items): app/controllers/admin/items_controller.rb app/helpers/admin/items_helper.rb Joe -- Posted via http://www.ruby-forum.com/.
2006 May 02
1
Newbie problem with Ajax and render partial
Hi all, I''m having this problem that I''m sure will take most of you all but two seconds to solve, but I''m very much a newbie. I read the documentation, googled for an answer, to no avail. I have simple page that lists items, each item as a row in a table. Each item has a rating and a link to increment/decrement rating. When using +/- on a rating on the first item,
2006 Mar 29
0
Intermittent error - undefined method ''destroy_without_callbacks''
When testing my app locally I''m getting intermittent errors which are driving me mad! The error is: NameError ((eval):1:in `alias_method'': undefined method `destroy_without_callbacks'' for class `Exercise''): Refreshing the browser sometimes fixes it, as does restarting WEBrick. Annoying to debug as it only happens intermittently. Any ideas on why this is
2007 Feb 24
1
Rails 1.2.2 link_to question
This didn''t get answered before, I''m not quite sure if the silence is telling me that I''m an idiot and it should be obvious, or if the silence indicates that no one knows why a simple thing shouldn''t work. I''ve tried this on a linux Centos install, and now my mac. I get the same result. In my view I have <%= link_to "New #{@item_class}",
2009 May 15
0
[PATCH server] final cleanup for service layer refactoring.
I've pulled out the no-longer-necessary remnants of the old way of handling auth and before_filters as well as fixing a couple bugs that had crept in along the way. Unit test fixes for the refactoring will follow in a subsequent patch. Signed-off-by: Scott Seago <sseago at redhat.com> --- src/app/controllers/application.rb | 46 ----------------
2009 Jul 06
0
[PATCH server] UI for accumulated uptime for VMs. (revised2)
This revised version of the patch incorporates jguiditta's sorting fix as well as some other changes required to make this work fully on the cloud UI side. --- src/app/controllers/pool_controller.rb | 2 +- src/app/controllers/resources_controller.rb | 4 +++- src/app/controllers/smart_pools_controller.rb | 7 +++---- src/app/helpers/application_helper.rb | 14
2009 Jul 02
1
[PATCH server] UI for accumulated uptime for VMs. (revised)
This revised version of the patch incorporates jguidditta's sorting fix as well as some other changes required to make this work fully on the cloud UI side. --- src/app/controllers/pool_controller.rb | 2 +- src/app/controllers/resources_controller.rb | 4 +++- src/app/controllers/smart_pools_controller.rb | 5 ++--- src/app/helpers/application_helper.rb | 14
2009 Jul 06
2
[PATCH server] UI for accumulated uptime for VMs. (revised3)
This revised version of the patch incorporates jguiditta's sorting fix as well as some other changes required to make this work fully on the cloud UI side. --- src/app/controllers/pool_controller.rb | 2 +- src/app/controllers/resources_controller.rb | 4 +++- src/app/controllers/smart_pools_controller.rb | 7 +++---- src/app/helpers/application_helper.rb | 14
2009 Jun 29
3
[PATCH server] UI for accumulated uptime for VMs.
There's still a problem with this working on the cloud side, but that can be resolved in a subsequent commit. --- src/app/controllers/pool_controller.rb | 2 +- src/app/controllers/resources_controller.rb | 7 ++++++- src/app/controllers/smart_pools_controller.rb | 5 ++--- src/app/helpers/application_helper.rb | 14 ++++++++++++++ src/app/models/vm.rb