Opened 12 years ago

Closed 12 years ago

#5743 closed defect (fixed)

ItemFileWriteStore chokes with reverting deletedItems

Reported by: benschell Owned by: Jared Jurkiewicz
Priority: high Milestone:
Component: Data Version: 1.0
Keywords: Cc:
Blocked By: Blocking:

Description

I've attached a test case. Using an existing data set, the organization is as follows:

Africa
|
|-----------|
Kenya     Egypt 
|
Nairobi

If you delete Egypt and Nairobi (doesn't matter the order), then attempt to revert the store and execute a new query, IFWS throws an error. In the given example, the _S (reference to the store) on the Kenya item has gone to null.

If referenceIntegrity is turned off, there are no issues.

Attachments (3)

IFRS_bug.html (2.0 KB) - added by benschell 12 years ago.
dojo.data.ItemFileWriteStore_20080204.patch (9.2 KB) - added by Jared Jurkiewicz 12 years ago.
dojo_1.0.X_dojo.data.ItemFileWriteStore_20080204.patch (9.5 KB) - added by Jared Jurkiewicz 12 years ago.
Backport of fix from 1.1 + alternate testcase for issue.

Download all attachments as: .zip

Change History (10)

Changed 12 years ago by benschell

Attachment: IFRS_bug.html added

comment:1 Changed 12 years ago by Jared Jurkiewicz

Located the problem. It's in the handling of modifiedItems and keeping the array of top level items consistent. The wring index was being used. Simple fix, turns out. Patch forthcoming.

Changed 12 years ago by Jared Jurkiewicz

comment:2 Changed 12 years ago by Jared Jurkiewicz

Updated patch to include a unit test for this problem. Will commit after running tests against multiple browsers as well as doh via rhino turns up clean.

comment:3 Changed 12 years ago by Jared Jurkiewicz

Browsers tested:

FireFox? 2.0.0.11: PASSED.

FireFox? 1.5.0.12: PASSED.

IE 6.0: PASSED.

IE 7.0: PASSED.

Opera 9.2: PASSED.

SeaMonkey? 1.1.2: PASSED.

Safari B3: PASSED.

D.O.H. executed with Rhino (commandline): PASSED.

comment:4 Changed 12 years ago by Jared Jurkiewicz

(In [12275]) Fix to ItemFileWriteStore? for reversion bug. refs #5743 !strict

comment:5 Changed 12 years ago by Jared Jurkiewicz

(In [12276]) Fix comment typo. refs #5743 !strict

Changed 12 years ago by Jared Jurkiewicz

Backport of fix from 1.1 + alternate testcase for issue.

comment:6 Changed 12 years ago by Jared Jurkiewicz

Dojo 1.0.X tested on:

Browsers tested:

FireFox?? 2.0.0.11: PASSED.

FireFox?? 1.5.0.12: PASSED.

IE 6.0: PASSED.

IE 7.0: PASSED.

Opera 9.2: PASSED.

SeaMonkey?? 1.1.2: PASSED.

Safari B3: PASSED.

D.O.H. executed with Rhino (commandline): PASSED.

comment:7 Changed 12 years ago by Jared Jurkiewicz

Resolution: fixed
Status: newclosed

(In [12277]) Backport of fix to revert code. fixes #5743 !strict

Note: See TracTickets for help on using tickets.