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.
Hi,Perhaps we can share a common data file with the single-line regexes?
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-qaYep, it has a context mode (similar to diff) as of yesterday.
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 interestingIt seems to identify the problematic line in almost (all?) the same
Sysop: | Keyop |
---|---|
Location: | Huddersfield, West Yorkshire, UK |
Users: | 296 |
Nodes: | 16 (2 / 14) |
Uptime: | 84:03:05 |
Calls: | 6,658 |
Calls today: | 4 |
Files: | 12,203 |
Messages: | 5,333,599 |
Posted today: | 1 |