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? [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? - running your tool against my test cases would be interesting Lucas