Closed Bug 51670 Opened 26 years ago Closed 25 years ago

Dependency loops are possible

Categories

(Bugzilla :: Bugzilla-General, defect, P3)

defect

Tracking

()

VERIFIED FIXED
Bugzilla 2.12

People

(Reporter: timeless, Assigned: tara)

References

()

Details

(Whiteboard: 2.12 [dataloss/corruption] 2.14)

Attachments

(2 files)

Steps to reproduce: Create a bug. Mark it as both blocking and blocked by some bug.
Simple case. I'm making this bug block itself. cyeh: enjoy
Blocks: 51670
Depends on: 51670
I've tried on landfill and cannot get it to create a loop in any way other than how you just did it here. The fix for this is simple, don't let a bug depend on itself. :) Hmm, it won't let me commit this bug with those dependencies there already, since it would create a loop. :) I need to clear it to submit this. But the fact that it lets you put it there the first time is definitely a bug.
No longer blocks: 51670
No longer depends on: 51670
Summary: Dependency loops are possible. → Can make a bug depend on itself
Whiteboard: 2.12
hmmm, nevermind, changing summary back. You can set the depends on and blocks to a different bug and it works, too. It checks both individually for conflicts without checking that they don't conflict with each other. oops. Being able to mark a bug as dependent on itself is a different problem, and that shouldn't happen either.
Summary: Can make a bug depend on itself → Dependency loops are possible
Yes there were a bunch of bugs with loops on landfill. The url was one. I should probably have links to the other bugs on landfill, but for reference while you have loops duplicate marking really fsck's up :-)
Whiteboard: 2.12 → 2.12 [dataloss/corruption]
*** Bug 45376 has been marked as a duplicate of this bug. ***
I have no idea on how I would go about fixing this, other than walking the dependency chain and seeing if I saw myself along it.
It already walks the chain to check them. You can't make a loop by changing either depends or blocks independently. You can make a loop if you change both. It walks the chain independently on each one to see if it loops, but doesn't compare them to each other. What it needs to do is when it walks the chain for "depends on", stash every bug number it hits in the process, then when it walks the chain for "blocks", error out if it hits any of the bugs found in the previous step.
I'm not convinced this is a 2.12 blocker.
i'll buy 2.14 if you can get it out w/in 2months of 2.12
Whiteboard: 2.12 [dataloss/corruption] → 2.12 [dataloss/corruption] 2.14
There are two fixes in this attachment. 1) Don't allow anyone to make a bug dependent or blocking in itself. Duh. 2) Create an intersection list of depends and blocks, and if they intersect, then fail.
fix checked into trunk
Status: NEW → RESOLVED
Closed: 25 years ago
Resolution: --- → FIXED
Sorry for the spam, but I needed to be able to query for all of these correctly.
Target Milestone: --- → Bugzilla 2.12
VERIFIED. I can no longer create circular dependency chains. Gerv
Status: RESOLVED → VERIFIED
Blocks: 82143
Moving closed bugs to Bugzilla product
Component: Bugzilla → Bugzilla-General
Product: Webtools → Bugzilla
Version: other → unspecified
Depends on: 113250
No longer depends on: 113250
QA Contact: matty_is_a_geek → default-qa
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: