Note: There are a few cases of duplicates in user autocompletion which are being worked on.

Validate instance documents on xforms-rebuild

RESOLVED FIXED

Status

Core Graveyard
XForms
P2
normal
RESOLVED FIXED
11 years ago
a year ago

People

(Reporter: Allan Beaufour, Assigned: Allan Beaufour)

Tracking

({fixed1.8.0.5, fixed1.8.1})

Trunk
fixed1.8.0.5, fixed1.8.1

Firefox Tracking Flags

(Not tracked)

Details

(URL)

Attachments

(2 attachments)

1.71 KB, application/xhtml+xml
Details
5.49 KB, patch
Doron Rosenberg (IBM)
: review+
smaug
: review+
Details | Diff | Splinter Review
(Assignee)

Description

11 years ago
Right now we only call ValidateDocument() on all instance documents on form load. Should we not be doing it for xforms-rebuild too?

If not, any new inserted nodes will not have the correct type set I guess.
(Assignee)

Comment 1

11 years ago
(In reply to comment #0)
> Right now we only call ValidateDocument() on all instance documents on form
> load. Should we not be doing it for xforms-rebuild too?
> 
> If not, any new inserted nodes will not have the correct type set I guess.

I'm pretty confident that we should do this.
Priority: -- → P2

Comment 2

11 years ago
It sure sounds logical, but how are we going to represent the invalid document to the user?  If it is failing due to and instance node missing an attribute, for example, and no one links to that attribute, then what do we do?  And even if a control does link to this missing attr then the control won't be there anyhow.  I guess we just log the error?
(Assignee)

Comment 3

11 years ago
(In reply to comment #2)
> It sure sounds logical, but how are we going to represent the invalid document
> to the user?  If it is failing due to and instance node missing an attribute,
> for example, and no one links to that attribute, then what do we do?  And even
> if a control does link to this missing attr then the control won't be there
> anyhow.  I guess we just log the error?

It's a bit tricky, I agree. Logging the error is also the best I can think of. Problem is that if we do not do it, schema types will not be correct.
(Assignee)

Comment 4

11 years ago
This needs to be done for bug 339217 to make sense.
Assignee: doronr → allan
Blocks: 339217
(Assignee)

Comment 5

11 years ago
Created attachment 223783 [details]
Testcase
(Assignee)

Updated

11 years ago
Status: NEW → ASSIGNED
(Assignee)

Comment 6

11 years ago
Created attachment 223784 [details] [diff] [review]
Patch
Attachment #223784 - Flags: review?(doronr)

Updated

11 years ago
Attachment #223784 - Flags: review?(doronr) → review+
(Assignee)

Updated

11 years ago
Attachment #223784 - Flags: review?(Olli.Pettay)

Updated

11 years ago
Attachment #223784 - Flags: review?(Olli.Pettay) → review+
(Assignee)

Comment 7

11 years ago
Fixed on trunk.
Status: ASSIGNED → RESOLVED
Last Resolved: 11 years ago
Resolution: --- → FIXED
Summary: Validate instance documents on xforms-rebuild? → Validate instance documents on xforms-rebuild
Whiteboard: xf-to-branch
(Assignee)

Updated

11 years ago
Keywords: fixed1.8.0.5
(Assignee)

Updated

11 years ago
Keywords: fixed1.8.1
(Assignee)

Updated

11 years ago
Whiteboard: xf-to-branch
Product: Core → Core Graveyard
You need to log in before you can comment on or make changes to this bug.