Go to:
Gentoo Home
Documentation
Forums
Lists
Bugs
Planet
Store
Wiki
Get Gentoo!
Gentoo's Bugzilla – Attachment 228927 Details for
Bug 315735
Repoman dies on metadata.xml USE-related errors without printing the full metadata.xml path
Home
|
New
–
[Ex]
|
Browse
|
Search
|
Privacy Policy
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
git-am format patch
0002-Make-metadata.xml-flag-errors-non-fatal-to-repoman.patch (text/plain), 1.88 KB, created by
Michał Górny
on 2010-04-23 22:05:00 UTC
(
hide
)
Description:
git-am format patch
Filename:
MIME Type:
Creator:
Michał Górny
Created:
2010-04-23 22:05:00 UTC
Size:
1.88 KB
patch
obsolete
>From f1a3daee3add4f261add553d0362c7abf4bf4248 Mon Sep 17 00:00:00 2001 >From: =?UTF-8?q?Micha=C5=82=20G=C3=B3rny?= <gentoo@mgorny.alt.pl> >Date: Sat, 17 Apr 2010 12:26:49 +0000 >Subject: [PATCH 2/3] Make metadata.xml <flag/> errors non-fatal to repoman. > >Previously, <flag/>-related errors in metadata.xml caused repoman >to abort the checks without even reporting the full path to broken >metadata.xml file. Now they are accounted as 'metadata.bad' errors. >--- > bin/repoman | 8 +++++++- > pym/repoman/utilities.py | 6 ++---- > 2 files changed, 9 insertions(+), 5 deletions(-) > >diff --git a/bin/repoman b/bin/repoman >index 23fcd4d..aa3a952 100755 >--- a/bin/repoman >+++ b/bin/repoman >@@ -1314,7 +1314,13 @@ for x in scanlist: > del e > else: > # load USE flags from metadata.xml >- utilities.parse_metadata_use(_metadata_xml, muselist) >+ try: >+ utilities.parse_metadata_use(_metadata_xml, muselist) >+ except portage.exception.ParseError as e: >+ metadata_bad = True >+ stats["metadata.bad"] += 1 >+ fails["metadata.bad"].append("%s/metadata.xml: %s" % (x, e)) >+ muselist = [] > > # Run other metadata.xml checkers > try: >diff --git a/pym/repoman/utilities.py b/pym/repoman/utilities.py >index 52ebba7..3050804 100644 >--- a/pym/repoman/utilities.py >+++ b/pym/repoman/utilities.py >@@ -119,14 +119,12 @@ def parse_metadata_use(xml_tree, uselist=None): > > flags = usetag[0].findall("flag") > if not flags: >- raise exception.ParseError("metadata.xml: " + \ >- "Malformed input: missing 'flag' tag(s)") >+ raise exception.ParseError("missing 'flag' tag(s)") > > for flag in flags: > pkg_flag = flag.get("name") > if pkg_flag is None: >- raise exception.ParseError("metadata.xml: " + \ >- "Malformed input: missing 'name' attribute for 'flag' tag") >+ raise exception.ParseError("missing 'name' attribute for 'flag' tag") > uselist.append(pkg_flag) > return uselist > >-- >1.7.0.4 >
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 315735
:
228141
| 228927