On Tue, Apr 06, 2021 at 08:49:01AM +0200, Lucas Nussbaum wrote: > Hi, > > On 05/04/21 at 15:14 +0100, Jelmer Vernooij wrote: > > The python3-buildlog-consultant package now has a "analyse-sbuild-log" > > command that can parse and analyse sbuild logs and in most cases > > identity the line or lines that explain why a build failed. > > > > E.g.: > > > > % analyse-sbuild-log --json ~/build.log > > {"stage": "build", "section": "Build", "lineno": 857, "kind": > > "missing-python-module", "details": {"module": "setuptools", > > "python_version": 3, "minimum_version": null}} > > > > This is what powers the line selection for the fragments shown by the > > Debian janitor for failed builds. > > Nice! > I've done something similar for my archive rebuild scripts[1]. Maybe we > should try merge efforts in some way? Perhaps we can share a common data file with the single-line regexes? That's where the bulk of my effort is today, and that seems like the easiest way to share efforts.
> [1] see log-parser-* in > https://salsa.debian.org/lucas/collab-qa-tools/-/tree/master/lib/collab-qa > test cases are > https://salsa.debian.org/lucas/collab-qa-tools/-/tree/master/test > > Some comments based on my own experience: > - did you consider adding a mode where it would output log lines that > precede the failure from the last interesting point, to make it easy to > file bugs? Yep, it has a context mode (similar to diff) as of yesterday. > - running your tool against my test cases would be interesting It seems to identify the problematic line in almost (all?) the same cases, but doesn't always provide a better classification than your script does - i.e. it finds python exceptions and segmentation faults but doesn't call them out as such. Cheers, Jelmer
signature.asc
Description: PGP signature