This project is archived and is in readonly mode.
Bad self referential HABTM associations should fail fast.
-
Steven Soroka
isn't this because the habtm isn't set up properly? don't you need to identify the names of the foreign_key and association_foreign_key ?
Sounds invalid to me.
-
Tom Lea
Indeed it is... but the fact that it pretends to work is the issue.
The whole thing seems to work just fine, we were several unit tests in before it started behaving oddly. Anyone who tests less thoroughly than we do here could well be cough out.
The patch makes it fail fast, not start magically guessing things.
-
Steven Soroka
Ahh.
code looks clean, fail early, fail often. +1
-
Tom Lea
New patch, error message was not as expected. Copied through relationship exception format by accident... oops.
Also rebased against HEAD while I was at it.
-
Repository
- State changed from new to resolved
(from [c896d56c6e5520346c260477f7d7f8bf951e72cc]) Ensure self referential HABTM associations raise an exception if association_foreign_key is missing. [#1252 Bad self referential HABTM associations should fail fast. state:resolved]
Signed-off-by: Pratik Naik pratiknaik@gmail.com http://github.com/rails/rails/co...
