After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 696184 - Add `make check-modulesets` target
Add `make check-modulesets` target
Status: RESOLVED FIXED
Product: jhbuild
Classification: Infrastructure
Component: general
unspecified
Other All
: Normal enhancement
: ---
Assigned To: Jhbuild maintainers
Jhbuild QA
Depends on:
Blocks: 696182
 
 
Reported: 2013-03-20 12:24 UTC by Philip Withnall
Modified: 2013-03-20 22:16 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
build: Include DTDs and XSL file in EXTRA_DIST (1.07 KB, patch)
2013-03-20 16:49 UTC, Philip Withnall
none Details | Review
build: Include DTDs and XSL file in EXTRA_DIST (1.06 KB, patch)
2013-03-20 16:52 UTC, Philip Withnall
committed Details | Review
install-check: Fix GCC warnings (806 bytes, patch)
2013-03-20 16:52 UTC, Philip Withnall
committed Details | Review
jhbuild: Fix validation of <dep> elements (1.43 KB, patch)
2013-03-20 16:52 UTC, Philip Withnall
committed Details | Review
modulesets: Update schemas to represent the state of the modulesets (7.96 KB, patch)
2013-03-20 16:52 UTC, Philip Withnall
committed Details | Review
modulesets: Remove unnecessary ‘version’ attribute from autotools elements (11.60 KB, patch)
2013-03-20 16:52 UTC, Philip Withnall
committed Details | Review
modulesets: Remove unused ‘autogen-sh’ attribute from non-autotools elements (6.86 KB, patch)
2013-03-20 16:52 UTC, Philip Withnall
committed Details | Review
modulesets: Fix use of non-existent ‘suggest’ element (5.06 KB, patch)
2013-03-20 16:52 UTC, Philip Withnall
committed Details | Review
modulesets: Reorder some elements to satisfy the schema (7.77 KB, patch)
2013-03-20 16:53 UTC, Philip Withnall
committed Details | Review
modulesets: Remove ‘check-target’ attribute from waf elements (3.18 KB, patch)
2013-03-20 16:53 UTC, Philip Withnall
committed Details | Review
modulesets: Fix use of ‘md5sum’ attribute (4.04 KB, patch)
2013-03-20 16:53 UTC, Philip Withnall
committed Details | Review
modulesets: Remove a duplicate element (741 bytes, patch)
2013-03-20 16:53 UTC, Philip Withnall
committed Details | Review
modulesets: Fix listing of patches for Avahi (1.33 KB, patch)
2013-03-20 16:53 UTC, Philip Withnall
committed Details | Review
build: Add ‘check’ and ‘check-modulesets’ targets to the build system (1.38 KB, patch)
2013-03-20 16:53 UTC, Philip Withnall
committed Details | Review

Description Philip Withnall 2013-03-20 12:24:53 UTC
This could be used to sanity-check the XML in the modulesets for validity, e.g. by a pre-receive git hook (see bug #696182). This might help to prevent build breakage due to typos in the XML.

Patch coming soon.
Comment 1 Philip Withnall 2013-03-20 16:49:41 UTC
Created attachment 239373 [details] [review]
build: Include DTDs and XSL file in EXTRA_DIST

Closes: bgo
Comment 2 Philip Withnall 2013-03-20 16:52:32 UTC
Created attachment 239374 [details] [review]
build: Include DTDs and XSL file in EXTRA_DIST
Comment 3 Philip Withnall 2013-03-20 16:52:35 UTC
Created attachment 239375 [details] [review]
install-check: Fix GCC warnings
Comment 4 Philip Withnall 2013-03-20 16:52:41 UTC
Created attachment 239376 [details] [review]
jhbuild: Fix validation of <dep> elements
Comment 5 Philip Withnall 2013-03-20 16:52:45 UTC
Created attachment 239377 [details] [review]
modulesets: Update schemas to represent the state of the modulesets

These updates are not exhaustive, but do mean that (with some fixes to be
committed shortly) all moduleset files now validate against both schemas.

Helps:
Comment 6 Philip Withnall 2013-03-20 16:52:50 UTC
Created attachment 239378 [details] [review]
modulesets: Remove unnecessary ‘version’ attribute from autotools elements

It isn’t in the schema, and doesn’t appear to be used by the Python.

Helps:
Comment 7 Philip Withnall 2013-03-20 16:52:55 UTC
Created attachment 239379 [details] [review]
modulesets: Remove unused ‘autogen-sh’ attribute from non-autotools elements

It doesn’t appear to be used by the Python, and wasn’t in the schema.

Helps:
Comment 8 Philip Withnall 2013-03-20 16:52:59 UTC
Created attachment 239380 [details] [review]
modulesets: Fix use of non-existent ‘suggest’ element

It should be ‘suggests’ instead.

Helps:
Comment 9 Philip Withnall 2013-03-20 16:53:05 UTC
Created attachment 239381 [details] [review]
modulesets: Reorder some elements to satisfy the schema

This doesn’t introduce any semantic changes; just reorders the elements
to match the order required by the schemas. Sigh.

Helps:
Comment 10 Philip Withnall 2013-03-20 16:53:10 UTC
Created attachment 239382 [details] [review]
modulesets: Remove ‘check-target’ attribute from waf elements

It appears to be unused in the Python and didn’t exist in the schema.

Helps:
Comment 11 Philip Withnall 2013-03-20 16:53:15 UTC
Created attachment 239383 [details] [review]
modulesets: Fix use of ‘md5sum’ attribute

The ‘md5’ attribute doesn’t exist.

Helps:
Comment 12 Philip Withnall 2013-03-20 16:53:20 UTC
Created attachment 239384 [details] [review]
modulesets: Remove a duplicate element

Helps:
Comment 13 Philip Withnall 2013-03-20 16:53:26 UTC
Created attachment 239385 [details] [review]
modulesets: Fix listing of patches for Avahi

The schema and parser require patches to be listed in a ‘patches’ element.

Helps:
Comment 14 Philip Withnall 2013-03-20 16:53:31 UTC
Created attachment 239386 [details] [review]
build: Add ‘check’ and ‘check-modulesets’ targets to the build system

This allows the validity of the modulesets’ XML to be checked without
building and installing jhbuild. This is useful for git pre-receive hooks
to prevent typos breaking the modulesets.

Closes:
Comment 15 Philip Withnall 2013-03-20 17:01:36 UTC
(In reply to comment #14)
> Closes:

Ignore these lines. Looks like git-bz misbehaving for me (sorry). The patches are OK.
Comment 16 Colin Walters 2013-03-20 17:55:27 UTC
Review of attachment 239374 [details] [review]:

Ok.  I don't think anyone is actively checking 'make dist', but it doesn't hurt to try =)
Comment 17 Colin Walters 2013-03-20 17:55:50 UTC
Review of attachment 239375 [details] [review]:

That's some old code you're fixing.  Nice!
Comment 18 Colin Walters 2013-03-20 17:56:37 UTC
Review of attachment 239376 [details] [review]:

Ah, yes.
Comment 19 Colin Walters 2013-03-20 17:57:53 UTC
Review of attachment 239377 [details] [review]:

Ah, very nice.  This should be a lot easier to maintain indeed if we check it continuously.
Comment 20 Colin Walters 2013-03-20 17:59:13 UTC
Review of attachment 239378 [details] [review]:

Mmm...careful here.  I believe the version is (or was?) used by the sysdeps infrastructure, acting as a minimum bound on the version.  Possibly that got changed around with the systemmodules stuff?  Needs investigation.

Even if it's not used by the code, I think we should add the version attribute to the schema, since it's still historically relevant.
Comment 21 Colin Walters 2013-03-20 18:00:28 UTC
Review of attachment 239379 [details] [review]:

That's odd that the distutils modules had autogen-sh="autoreconf".  I wonder if that's just something that got cargo-culted.  Did you try building one of the distutils modules?
Comment 22 Colin Walters 2013-03-20 18:00:44 UTC
Review of attachment 239380 [details] [review]:

Yes.
Comment 23 Colin Walters 2013-03-20 18:01:20 UTC
Review of attachment 239381 [details] [review]:

Ah.  Oh well, makes sense to have them in a consistent order.
Comment 24 Colin Walters 2013-03-20 18:03:48 UTC
Review of attachment 239382 [details] [review]:

Hmm; true, looks like the current waf modtype ignores it.
Comment 25 Colin Walters 2013-03-20 18:04:30 UTC
Review of attachment 239383 [details] [review]:

Surprising no one noticed this before.
Comment 26 Colin Walters 2013-03-20 18:04:44 UTC
Review of attachment 239384 [details] [review]:

Prune the branches...
Comment 27 Colin Walters 2013-03-20 18:05:04 UTC
Review of attachment 239385 [details] [review]:

Ok.
Comment 28 Colin Walters 2013-03-20 18:05:31 UTC
Review of attachment 239386 [details] [review]:

Nice.
Comment 29 Philip Withnall 2013-03-20 21:20:05 UTC
(In reply to comment #20)
> Review of attachment 239378 [details] [review]:
> 
> Mmm...careful here.  I believe the version is (or was?) used by the sysdeps
> infrastructure, acting as a minimum bound on the version.  Possibly that got
> changed around with the systemmodules stuff?  Needs investigation.

I just went through the output of `git grep version` and I can’t see anything which touches the ‘version’ attribute on elements other than <branch>.

> Even if it's not used by the code, I think we should add the version attribute
> to the schema, since it's still historically relevant.

Why? The schema isn’t going to be used to validate anything except the modulesets currently in the repository.

(In reply to comment #21)
> Review of attachment 239379 [details] [review]:
> 
> That's odd that the distutils modules had autogen-sh="autoreconf".  I wonder if
> that's just something that got cargo-culted.  Did you try building one of the
> distutils modules?

I just tried building postr with and without the attribute, and it fails with the same error message (“error: data/postr.desktop.in: No such file or directory”) both times. Grepping the jhbuild source code for ‘autogen-sh’ shows it’s only used in the autotools module.
Comment 30 Colin Walters 2013-03-20 21:35:58 UTC
(In reply to comment #29)
> (In reply to comment #20)
> > Review of attachment 239378 [details] [review] [details]:
> > 
> > Mmm...careful here.  I believe the version is (or was?) used by the sysdeps
> > infrastructure, acting as a minimum bound on the version.  Possibly that got
> > changed around with the systemmodules stuff?  Needs investigation.
> 
> I just went through the output of `git grep version` and I can’t see anything
> which touches the ‘version’ attribute on elements other than <branch>.

Oh, I took another look at this - it's duplicating the version= attribute already on the branch tag.  Ok, makes a lot more sense. 

Consider that and the other reviewed patches a-c-n then.  Thanks!
Comment 31 Philip Withnall 2013-03-20 22:13:21 UTC
commit c26798c79427369174357333501d16f80a78738d
Author: Philip Withnall <philip@tecnocode.co.uk>
Date:   Wed Mar 20 16:43:37 2013 +0000

    build: Add ‘check’ and ‘check-modulesets’ targets to the build system
    
    This allows the validity of the modulesets’ XML to be checked without
    building and installing jhbuild. This is useful for git pre-receive hooks
    to prevent typos breaking the modulesets.
    
    Closes: https://bugzilla.gnome.org/show_bug.cgi?id=696184

 Makefile.am | 12 ++++++++++++
 1 file changed, 12 insertions(+)

commit 1fdc7a3739387f18827aa3328f01d9b3d33259ad
Author: Philip Withnall <philip@tecnocode.co.uk>
Date:   Wed Mar 20 16:43:09 2013 +0000

    modulesets: Fix listing of patches for Avahi
    
    The schema and parser require patches to be listed in a ‘patches’ element.
    
    Helps: https://bugzilla.gnome.org/show_bug.cgi?id=696184

 modulesets/gnome-suites-core-3.0.modules | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

commit 2b56182ba3ba722e73cb693475fb83940044f3e7
Author: Philip Withnall <philip@tecnocode.co.uk>
Date:   Wed Mar 20 16:42:51 2013 +0000

    modulesets: Remove a duplicate element
    
    Helps: https://bugzilla.gnome.org/show_bug.cgi?id=696184

 modulesets/gnome-apps-3.6.modules | 1 -
 1 file changed, 1 deletion(-)

commit 2ad6a2643a6e136260fc53765f3a9841cd6b987b
Author: Philip Withnall <philip@tecnocode.co.uk>
Date:   Wed Mar 20 16:42:14 2013 +0000

    modulesets: Fix use of ‘md5sum’ attribute
    
    The ‘md5’ attribute doesn’t exist.
    
    Helps: https://bugzilla.gnome.org/show_bug.cgi?id=696184

 modulesets/gnome-world-3.0.modules  | 2 +-
 modulesets/gnome-world-3.10.modules | 2 +-
 modulesets/gnome-world-3.2.modules  | 2 +-
 modulesets/gnome-world-3.4.modules  | 2 +-
 modulesets/gnome-world-3.6.modules  | 2 +-
 modulesets/gnome-world-3.8.modules  | 2 +-
 6 files changed, 6 insertions(+), 6 deletions(-)

commit 5c74cb47e063e5db5d30901b186bb586a4e0c106
Author: Philip Withnall <philip@tecnocode.co.uk>
Date:   Wed Mar 20 16:41:36 2013 +0000

    modulesets: Remove ‘check-target’ attribute from waf elements
    
    It appears to be unused in the Python and didn’t exist in the schema.
    
    Helps: https://bugzilla.gnome.org/show_bug.cgi?id=696184

 modulesets/gnome-apps-3.0.modules   | 2 +-
 modulesets/gnome-apps-3.2.modules   | 2 +-
 modulesets/gnome-world-3.10.modules | 2 +-
 modulesets/gnome-world-3.4.modules  | 2 +-
 modulesets/gnome-world-3.6.modules  | 2 +-
 modulesets/gnome-world-3.8.modules  | 2 +-
 6 files changed, 6 insertions(+), 6 deletions(-)

commit 28d73cc2a397dd0b1e804fc85b23219ed9fe1d6d
Author: Philip Withnall <philip@tecnocode.co.uk>
Date:   Wed Mar 20 16:40:34 2013 +0000

    modulesets: Reorder some elements to satisfy the schema
    
    This doesn’t introduce any semantic changes; just reorders the elements
    to match the order required by the schemas. Sigh.
    
    Helps: https://bugzilla.gnome.org/show_bug.cgi?id=696184

 modulesets/gnome-suites-core-deps-3.0.modules  |  6 +++---
 modulesets/gnome-suites-core-deps-3.10.modules |  8 ++++----
 modulesets/gnome-suites-core-deps-3.2.modules  |  6 +++---
 modulesets/gnome-suites-core-deps-3.4.modules  | 10 +++++-----
 modulesets/gnome-suites-core-deps-3.6.modules  |  8 ++++----
 modulesets/gnome-suites-core-deps-3.8.modules  |  8 ++++----
 modulesets/gnome-sysdeps-3.10.modules          |  4 ++--
 modulesets/gnome-sysdeps-3.8.modules           |  4 ++--
 8 files changed, 27 insertions(+), 27 deletions(-)

commit 18f01e01d7c17a5a718a2a64051f0cf56e5dc8e1
Author: Philip Withnall <philip@tecnocode.co.uk>
Date:   Wed Mar 20 16:39:22 2013 +0000

    modulesets: Fix use of non-existent ‘suggest’ element
    
    It should be ‘suggests’ instead.
    
    Helps: https://bugzilla.gnome.org/show_bug.cgi?id=696184

 modulesets/gnome-apps-3.10.modules        | 4 ++--
 modulesets/gnome-apps-3.6.modules         | 4 ++--
 modulesets/gnome-apps-3.8.modules         | 4 ++--
 modulesets/gnome-suites-core-3.10.modules | 8 ++++----
 modulesets/gnome-suites-core-3.4.modules  | 4 ++--
 modulesets/gnome-suites-core-3.6.modules  | 4 ++--
 modulesets/gnome-suites-core-3.8.modules  | 8 ++++----
 7 files changed, 18 insertions(+), 18 deletions(-)

commit c0d0b4fe56c5d13e96ad24d457ef177c5677698a
Author: Philip Withnall <philip@tecnocode.co.uk>
Date:   Wed Mar 20 16:37:49 2013 +0000

    modulesets: Remove unused ‘autogen-sh’ attribute from non-autotools elements
    
    It doesn’t appear to be used by the Python, and wasn’t in the schema.
    Building a distutils module with and without it makes no difference.
    
    Helps: https://bugzilla.gnome.org/show_bug.cgi?id=696184

 modulesets/gnome-apps-3.0.modules   | 3 +--
 modulesets/gnome-apps-3.2.modules   | 3 +--
 modulesets/gnome-apps-3.4.modules   | 3 +--
 modulesets/gnome-world-3.0.modules  | 4 ++--
 modulesets/gnome-world-3.10.modules | 4 ++--
 modulesets/gnome-world-3.2.modules  | 4 ++--
 modulesets/gnome-world-3.4.modules  | 4 ++--
 modulesets/gnome-world-3.6.modules  | 4 ++--
 modulesets/gnome-world-3.8.modules  | 4 ++--
 9 files changed, 15 insertions(+), 18 deletions(-)

commit 094014266bd4a0f90d324feec7f42b2a5bef983e
Author: Philip Withnall <philip@tecnocode.co.uk>
Date:   Wed Mar 20 16:35:39 2013 +0000

    modulesets: Remove unnecessary ‘version’ attribute from autotools elements
    
    It isn’t in the schema, and doesn’t appear to be used by the Python. It
    duplicates the same attribute already on the <branch> element.
    
    Helps: https://bugzilla.gnome.org/show_bug.cgi?id=696184

 modulesets/gnome-apps-3.0.modules                  | 2 +-
 modulesets/gnome-suites-core-3.10.modules          | 2 +-
 modulesets/gnome-suites-core-3.4.modules           | 2 +-
 modulesets/gnome-suites-core-3.6.modules           | 2 +-
 modulesets/gnome-suites-core-3.8.modules           | 2 +-
 modulesets/gnome-suites-core-deps-3.0.modules      | 2 +-
 modulesets/gnome-suites-core-deps-3.10.modules     | 4 ++--
 modulesets/gnome-suites-core-deps-3.2.modules      | 2 +-
 modulesets/gnome-suites-core-deps-3.4.modules      | 2 +-
 modulesets/gnome-suites-core-deps-3.6.modules      | 2 +-
 modulesets/gnome-suites-core-deps-3.8.modules      | 4 ++--
 modulesets/gnome-suites-core-deps-base-3.4.modules | 6 +++---
 modulesets/gnome-suites-core-deps-base-3.6.modules | 6 +++---
 13 files changed, 19 insertions(+), 19 deletions(-)

commit 6ed4fb5f885f7ce017e46420f8836b7d5483ac95
Author: Philip Withnall <philip@tecnocode.co.uk>
Date:   Wed Mar 20 16:11:47 2013 +0000

    modulesets: Update schemas to represent the state of the modulesets
    
    These updates are not exhaustive, but do mean that (with some fixes to be
    committed shortly) all moduleset files now validate against both schemas.
    
    Helps: https://bugzilla.gnome.org/show_bug.cgi?id=696184
 modulesets/moduleset.dtd | 25 ++++++++++++++++---------
 modulesets/moduleset.rnc | 42 +++++++++++++++++++++++++++++-------------
 2 files changed, 45 insertions(+), 22 deletions(-)

commit 7cdf167a0bb644cd229de9247234fc13826829fd
Author: Philip Withnall <philip@tecnocode.co.uk>
Date:   Wed Mar 20 16:10:31 2013 +0000

    jhbuild: Fix validation of <dep> elements

 jhbuild/modtypes/__init__.py | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

commit 0b1d66d9b25118e82cbf0e4b045db800c2046060
Author: Philip Withnall <philip@tecnocode.co.uk>
Date:   Wed Mar 20 12:20:59 2013 +0000

    install-check: Fix GCC warnings

 install-check.c | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

commit 7f7b5892256a44ecb95b5660a465547f8a1248f3
Author: Philip Withnall <philip@tecnocode.co.uk>
Date:   Wed Mar 20 12:10:23 2013 +0000

    build: Include DTDs and XSL file in EXTRA_DIST

 Makefile.am | 9 +++++++--
 1 file changed, 7 insertions(+), 2 deletions(-)