A blank ts_control file leads to a schema validation error

Bug #1055802 reported by Joe Talbott
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
UTAH
Fix Released
Low
Javier Collado

Bug Description

Since none of the metadata in the ts_control file is mandatory a blank ts_control file should be accepted.

The error I receive is:

'testit' test suite control file invalid: 'testit/ts_control'
Detailed information: None is not of type 'object'

The expected behavior is that the file should be accepted by the schema validation code.

Related branches

Revision history for this message
Javier Collado (javier.collado) wrote :

@Joe

I think that the problem here is that the schema validation expects a dictionary object and instead of None. Hence, the minimum file must contain '{}'.

If you want to support empty files, then the schema should be updated or we can provide a default value is the file is empty. I think I'd be in favor of the latter, since I think it's better to keep the schema as simple as possible for this.

Aside from empty files, would you like to support not having any file at all as well?

Revision history for this message
Joe Talbott (joetalbott) wrote : Re: [Bug 1055802] Re: A blank ts_control file leads to a schema validation error

On Fri, Oct 05, 2012 at 10:19:17AM -0000, Javier Collado wrote:
> @Joe
>
> I think that the problem here is that the schema validation expects a
> dictionary object and instead of None. Hence, the minimum file must
> contain '{}'.
>
> If you want to support empty files, then the schema should be updated or
> we can provide a default value is the file is empty. I think I'd be in
> favor of the latter, since I think it's better to keep the schema as
> simple as possible for this.
>
> Aside from empty files, would you like to support not having any file at
> all as well?

@Javier

I agree with the second option as well. I think we should also allow
for no ts_control file since there aren't any mandatory fields there.

Joe
>
> --
> You received this bug notification because you are subscribed to the bug
> report.
> https://bugs.launchpad.net/bugs/1055802
>
> Title:
> A blank ts_control file leads to a schema validation error
>
> Status in Ubuntu Test Automation Harness:
> New
>
> Bug description:
> Since none of the metadata in the ts_control file is mandatory a blank
> ts_control file should be accepted.
>
> The error I receive is:
>
> 'testit' test suite control file invalid: 'testit/ts_control'
> Detailed information: None is not of type 'object'
>
> The expected behavior is that the file should be accepted by the
> schema validation code.
>
> To manage notifications about this bug go to:
> https://bugs.launchpad.net/utah/+bug/1055802/+subscriptions

Changed in utah:
status: New → Triaged
importance: Undecided → Low
assignee: nobody → Javier Collado (javier.collado)
status: Triaged → In Progress
Changed in utah:
status: In Progress → Fix Committed
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.