Bug#243729: machine parseable version of lintian output

2008-08-07 Thread Stefano Zacchiroli
retitle 243729 [pts] todo should list lintian warning/error summary
thanks

Dear Lintian maintainers,
  I would like to fix #243729 by adding in the TODO section of the PTS
web interface a summary of lintian blames for a given source package. To
do that I would need a machine parseable version of the lintian output.

Is there anything like that available somewhere? I wouldn't like having
to scrape HTML ...

TIA,
Cheers.

-- 
Stefano Zacchiroli -*- PhD in Computer Science \ PostDoc @ Univ. Paris 7
[EMAIL PROTECTED],pps.jussieu.fr,debian.org} -<>- http://upsilon.cc/zack/
I'm still an SGML person,this newfangled /\ All one has to do is hit the
XML stuff is so ... simplistic  -- Manoj \/ right keys at the right time



-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]



Bug#243729: machine parseable version of lintian output

2008-08-07 Thread Russ Allbery
Stefano Zacchiroli <[EMAIL PROTECTED]> writes:

> retitle 243729 [pts] todo should list lintian warning/error summary
> thanks
>
> Dear Lintian maintainers,
>   I would like to fix #243729 by adding in the TODO section of the PTS
> web interface a summary of lintian blames for a given source package. To
> do that I would need a machine parseable version of the lintian output.
>
> Is there anything like that available somewhere? I wouldn't like having
> to scrape HTML ...

http://lintian.debian.org/lintian.log

-- 
Russ Allbery ([EMAIL PROTECTED])   



-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]



Bug#243729: machine parseable version of lintian output

2008-08-07 Thread Stefano Zacchiroli
On Thu, Aug 07, 2008 at 08:38:31PM -0700, Russ Allbery wrote:
> http://lintian.debian.org/lintian.log

Cool. One questions and one suggestion then:

- question: is there already available reusable parsing code for that
  format? If not I can hack up something to be embedded into
  python-debian, as I presume the code can be useful to somebody else

- suggestion: please link the above URL from the Lintian website, so
  that other people like me will avoid bothering you in the future with
  this request :)

Cheers.

-- 
Stefano Zacchiroli -*- PhD in Computer Science \ PostDoc @ Univ. Paris 7
[EMAIL PROTECTED],pps.jussieu.fr,debian.org} -<>- http://upsilon.cc/zack/
I'm still an SGML person,this newfangled /\ All one has to do is hit the
XML stuff is so ... simplistic  -- Manoj \/ right keys at the right time



-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]



Bug#243729: machine parseable version of lintian output

2008-08-07 Thread Russ Allbery
Stefano Zacchiroli <[EMAIL PROTECTED]> writes:

> Cool. One questions and one suggestion then:
>
> - question: is there already available reusable parsing code for that
>   format? If not I can hack up something to be embedded into
>   python-debian, as I presume the code can be useful to somebody else

There isn't parsing code in Python.  :)

It's a fairly trivial regex parse, which is done by the Lintian scripts
but not in a way that is very extractable (mostly because it's so trivial
that we've not bothered).

next if $line /^N:/;
next unless $line =~ /^([EWIXO]): (\S+)(?: (\S+))?: (\S+)(?:\s+(.*))?/;
my ($code, $package, $type, $tag, $extra) = ($1, $2, $3, $4, $5);
$type = 'binary' unless $type;

$type should be source, binary, or udeb.  $package is the name of the
package of that type, $tag is the tag, and $extra is any additional tag
data.  The $code will be E(rror), W(arning), I(nfo), (e)X(perimental), or
O(verridden).  Lines starting with N: are informational output that should
be ignored.

> - suggestion: please link the above URL from the Lintian website, so
>   that other people like me will avoid bothering you in the future with
>   this request :)

Will do.

-- 
Russ Allbery ([EMAIL PROTECTED])   



-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]