Ruby on Rails | Screencasts | Download | Documentation | Weblog | Community | Source

Ticket #286 (closed defect: worksforme)

Opened 5 years ago

Last modified 3 years ago

:dependent breaks on a chain

Reported by: Marten Assigned to: David
Priority: high Milestone: 0.9
Component: ActiveRecord Version: 0.8
Severity: critical Keywords:
Cc:

Description

Say you have a

ModelA has_many :model_b, :dependent => true
ModelB has_many :model_c, :dependent => true

Calling

some_model_a.destroy

yields an error because it tries to destroy the model_c's after it's destroyed the model_b's. Or atleast, that's what I think is going on.

Change History

12/12/04 18:14:24 changed by david

  • status changed from new to closed.
  • resolution set to worksforme.

I attempted to recreate this issue in http://dev.rubyonrails.org/trac.cgi/changeset/132 but couldn't get it to fail. Please reopen if you can track down the cause more specifically.

12/13/04 19:45:06 changed by scott

As a note, I belive this issue is properly resolved with some of the other AR fixes that are going into 0.9.0. I also could not reproduce this problem (but did experience it), but it has resolved for me with the soon to be 0.9.0 code.

10/03/05 17:26:55 changed by 컹유쩡

<A HREF="http://wow.cn.ms" target="_blank">

**뽀.르.렸.p.2.p.공.유.중** 전.세.계.동.영.상.무.료.공.유.중 A.V.걸.들.렸,모,자,이,크,무,삭,제,공,유,중

http://wow.cn.ms

http://wow.cn.ms

삭@@@@제: ppp99

</a>

(follow-up: ↓ 14 ) 10/10/05 20:55:38 changed by 옹박이

<A HREF="http://www.bogoo.da.ru" target="_blank">

성,인,전,용,비,공,개,p,2,p,공,개,중 미,국,서,버 한,글,화,로,공,개,중 당,나,귀 비,공,개 서,버,성,인,자,료 미,성,렄,자,출,잠,금,지

http://www.bogoo.da.ru

http://www.bogoo.da.ru

삭----제: cocoi

</a>

10/15/05 02:19:31 changed by 옹박이

<A HREF="http://www.bogoo.da.ru" target="_blank">

성,인,전,용,비,공,개,p,2,p,공,개,중 미,국,서,버 한,글,화,로,공,개,중 당,나,귀 비,공,개 서,버,성,인,자,료 미,성,렄,자,출,잠,금,지

http://www.bogoo.da.ru

http://www.bogoo.da.ru

삭----제: cocoi

</a>

11/06/05 00:43:56 changed by 겅유실

<A HREF="http://www.joa.hk.ms" target="_blank">

(P.2.P)방.대.한.자.료.공.유 자.료.만.땠! 무 엇 이 든 지 모 든 자 료 가 다있습니다,

http://www.joa.hk.ms

http://www.joa.hk.ms

암/호 joa22

</a>

11/12/05 10:05:42 changed by 조아조아

<A HREF="http://www.p2p.au.ms" target="_blank">

성.인.무.제.한 자.료.공.유

http://www.p2p.au.ms

http://www.p2p.au.ms

암/호 0u0u5

</a>

11/17/05 06:17:56 changed by 루마니아

<A HREF="http://p2p.au.ms" target="_blank">

(성,인)자,료1800여편이 넘는 풀무비 공유중

http://p2p.au.ms

http://p2p.au.ms

삭,제,비,번 = cooo8

</a>

11/23/05 07:37:47 changed by 루마니아

<A HREF="http://p2p.au.ms" target="_blank">

(성,인)자,료1800여편이 넘는 풀무비 공유중

http://p2p.au.ms

http://p2p.au.ms

삭,제,비,번 = cooo8

</a>

12/20/05 04:15:30 changed by 껑유중

<A HREF="http://www.xdx.jp.pn" target="_blank">

(최,대규,모)일.본.뽀.르.렸.p.2.p 공,유,중

http://www.xdx.jp.pn

http://www.xdx.jp.pn

삭/제 momo8

</a>

01/04/06 03:03:20 changed by 껑유중

<A HREF="http://www.xdx.jp.pn" target="_blank">

(최,대규,모)일.본.뽀.르.렸.p.2.p 공,유,중

http://www.xdx.jp.pn

http://www.xdx.jp.pn

삭/제 momo8

</a>

01/18/06 09:56:55 changed by 수퍼맨

<A HREF="http://www.aav.us.pn" target="_blank">

무-제-한..성/인/동/영/상.공-유-중 미-국 일-본 프-랑-스 무-삭-제 공-유-중

http://www.aav.us.pn

http://www.aav.us.pn

http://www.aav.us.pn

http://www.aav.us.pn

삭#제 aav444

</a>

(in reply to: ↑ description ) 09/10/06 04:49:35 changed by anonymous

Replying to Marten:

Say you have a {{{ ModelA has_many :model_b, :dependent => true ModelB has_many :model_c, :dependent => true }}} Calling {{{ some_model_a.destroy }}} yields an error because it tries to destroy the model_c's after it's destroyed the model_b's. Or atleast, that's what I think is going on.

(in reply to: ↑ 4 ; follow-up: ↓ 15 ) 09/10/06 05:11:12 changed by anonymous

Replying to 옹박이:

<A HREF="http://www.bogoo.da.ru" target="_blank"> 성,인,전,용,비,ê³µ,개,p,2,p,ê³µ,개,중 미,êµ­,서,버 한,글,화,로,ê³µ,개,중 당,나,귀 비,ê³µ,개 서,버,성,인,자,료 미,성,ëÂ

„,자,출,잠,금,지

http://www.bogoo.da.ru http://www.bogoo.da.ru 삭----제: cocoi </a>

(in reply to: ↑ 14 ) 09/10/06 05:12:17 changed by anonymous

Replying to anonymous:

Replying to 옹박이:

<A HREF="http://www.bogoo.da.ru" target="_blank"> 성,인,전,용,비,ê³µ,개,p,2,p,ê³µ,개,중 미,êµ­,서,버 한,글,화,로,ê³µ,개,중 당,나,귀 비,ê³µ,개 서,버,성,인,자,료 미,성,ëÂ

„,자,출,잠,금,지

http://www.bogoo.da.ru http://www.bogoo.da.ru 삭----제: cocoi </a>