guix-patches
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[bug#70499] [PATCH v2 0/3] Lint package order.


From: Ludovic Courtès
Subject: [bug#70499] [PATCH v2 0/3] Lint package order.
Date: Sat, 25 May 2024 16:06:45 +0200
User-agent: Gnus/5.13 (Gnus v5.13)

Hi Herman,

Herman Rimm <herman@rimm.ee> skribis:

> I do not think 'find-unordered-packages' would be useful for e.g. guix
> style, so I made a similar procedure in (guix scripts lint) instead.  It
> is implemented with 'fold-packages' to get package records to pass to
> the 'run-checkers' procedure.  So now you can use guix lint with
> --whole-file to also lint the package ordering, for example:

Nice.

>   $ guix lint -f gnu/packages/matrix.scm -n
>   gnu/packages/matrix.scm:161:0: python-matrix-nio@0.20.2: breaks from 
> alphabetical order
>   gnu/packages/matrix.scm:244:0: pantalaimon@0.10.5: breaks from alphabetical 
> order
>
> However the alphabetical order lint warnings only appear once another
> type of lint warning is emitted, or when end of file is reached and
> linting finishes. So if few checkers are enabled, it takes a few seconds
> before anything is output for large module files, like 'crates-io.scm'.
> Can this be fixed easily?

I’m not sure I understand.  The alpabetical checker is part of another
patch set, right?  (I know I’ve seen it, but I’m afraid I’ve lost track
of it. :-))

Anyway, we can and should discuss ‘--whole-file’ independently of the
alphabetical-order checker.

>   guix: Move ‘package-location<?’ to (guix packages).
>   ui: Make 'user-module' parameter of 'load*' optional.
>   scripts: lint: Add 'whole-file' option with ordering lint.

This LGTM modulo minor issues:

  • The second patch looks unrelated to ‘--whole-file’, I’d drop it from
    this series.

  • The third patch misses just one thing: a test in
    ‘tests/guix-lint.sh’.

Could you send an updated patch series?

Thanks, and apologies for the delay!

Ludo’.





reply via email to

[Prev in Thread] Current Thread [Next in Thread]