On Tue, Apr 06, 2021 at 09:48:27AM +0200, Helmut Grohne wrote:
> on many of my build logs, analyse-sbuild-log fails like this:
> 
> | Failed stage: build
> | Traceback (most recent call last):
> |   File "/usr/bin/analyse-sbuild-log", line 33, in <module>
> |     sys.exit(load_entry_point('buildlog-consultant==0.0.7', 
> 'console_scripts', 'analyse-sbuild-log')())
> |   File "/usr/lib/python3/dist-packages/buildlog_consultant/sbuild.py", line 
> 985, in main
> |     failure = worker_failure_from_sbuild_log(sbuildlog)
> |   File "/usr/lib/python3/dist-packages/buildlog_consultant/sbuild.py", line 
> 805, in worker_failure_from_sbuild_log
> |     overall_failure = FAILED_STAGE_FAIL_FINDERS[failed_stage](sbuildlog, 
> failed_stage)
> |   File "/usr/lib/python3/dist-packages/buildlog_consultant/sbuild.py", line 
> 685, in find_failure_build
> |     failed_stage, description, error=error, phase=phase,
> | UnboundLocalError: local variable 'phase' referenced before assignment
> 
> You can find an example log at
> http://crossqa.debian.net/build/wp2latex_3.88-4_ppc64el_20200401090810.log.xz
> (optionally dropping the .xz suffix if you prefer). A minimal reproducer
> seems to be:
> 
> | 
> +------------------------------------------------------------------------------+
> | | Build                                                                     
>    |
> | 
> +------------------------------------------------------------------------------+
> | pass1.cc:560:17: warning: ignoring return value of ‘size_t fread(void*, 
> size_t, size_t, FILE*)’, declared with attribute warn_unused_result 
> [-Wunused-result]
> | 
> +------------------------------------------------------------------------------+
> | | Summary                                                                   
>    |
> | 
> +------------------------------------------------------------------------------+
> | Fail-Stage: build
Thanks - this is actually already fixed in master, but it's not in
unstable yet. I'll mark this bug as fixed with the next release.

> During fuzzing analyze-sbuild-log a significant number of other
> exceptions surfaced. I suggest that you start fuzzing it to make it more
> robust against bad input.
How do you fuzz?

Jelmer

-- 
Jelmer Vernooij <[email protected]>
PGP Key: https://www.jelmer.uk/D729A457.asc

Attachment: signature.asc
Description: PGP signature

Reply via email to