8fd08590

By: Tom Sydney Kerckhove <syd@cs-syd.eu>

hopinion and the dangerous functions list

Both judge the Haskell against standards this repository was written to and
had no way of enforcing. Between them they found 53 and 37 things.

hopinion needed routeros-check to be in haskellPackages rather than built
beside it, since what it reads is what the compiler wrote down, and only
the set that builds a package has that. It runs in a nixpkgs of its own so
that nothing it does can change what gets built.

What it found, both of them rules already written down here: strings
concatenated with <> rather than put in a list, and FilePath in this
repository's own signatures. The second is the interesting one. The
reported path is now SomeBase File, which says what FilePath could not:
whether it is absolute or relative. diagnose still wants a String and gets
one at the call, which is what converting at the edge means.

The dangerous functions found four uses of read, which is partial, and
seven of Data.Text.IO.readFile, which decodes by locale. A nix build has
no locale, so a configuration with a comment outside ascii would have
failed to be read there and nowhere else. Both are gone: readMaybe, and a
File module that reads and writes utf-8 whatever the environment says.

hlint and hopinion disagree about strings: one wants ++, the other wants a
list. The list is what this repository has chosen, so that hint is
ignored, with the reason written where the ignore is.

Nothing was suppressed to make either pass.
GitHub

Total

4h03m57s

Created Started Finished

Time to Start Worker time Duration Time to finish Idle
Config 3m34s 0s 0s 3m35s 3m34s
Eval 3m36s 10s 10s 3m47s 1s
Build 3m46s 4h00m16s 4h03m45s 4h07m32s 2h03m29s
Suite 3m34s 4h00m27s 4h03m57s 4h07m32s 2h07m05s

Timeline

Config Eval Build Failed Retried Compressed gap
0s8m9m10m11m12m13m14m15m16m17m18m19m20m21m22m23m24m25m26m27m28m29m30m31m32m33m34m35m36m37m38m39m40m41m42m43m44m45m46m47m48m49m50m51m52m53m54m55m56m57m58m59m1h0m1h1m1h2m1h3m1h4m1h5m1h6m1h7m1h8m1h9m1h10m1h11m1h12m1h13m1h14m1h15m1h16m1h17m1h18m1h19m1h20m1h21m1h22m1h23m1h24m1h25m1h26m1h27m1h28m1h29m1h30m1h31m1h32m1h33m1h34m1h35m1h36m1h37m1h38m1h39m1h40m1h41m1h42m1h43m1h44m1h45m1h46m1h47m1h48m1h49m1h50m1h51m1h52m1h53m1h54m1h55m1h56m1h57m1h58m1h59m2h0m2h1m2h2m2h3m2h4m2h5m2h6m2h7m2h8m2h9m2h10m2h11m2h12m2h13m2h14m2h15m2h16m2h17m2h18m2h19m2h20m2h21m2h22m2h23m2h24m2h25m2h26m2h27m2h28m2h29m2h30m2h31m2h32m2h33m2h34m2h35m2h36m2h37m2h38m2h39m2h40m2h41m2h42m2h43m2h44m2h45m2h46m2h47m2h48m2h49m2h50m2h51m2h52m2h53m2h54m2h55m2h56m2h57m2h58m2h59m3h0m3h1m3h2m3h3m3h4m3h5m3h6m3h7m3h8m3h9m3h10m3h11m3h12m3h13m3h14m3h15m3h16m3h17m3h18m3h19m3h20m3h21m3h22m3h23m3h24m3h25m3h26m3h27m3h28m3h29m3h30m3h31m3h32m3h33m3h34m3h35m3h36m3h37m3h38m3h39m3h40m3h41m3h42m3h43m3h44m3h45m3h46m3h47m3h48m3h49m3h50m3h51m3h52m3h53m3h54m3h55m3h56m3h57m3h58m3h59m4h0m4h1m4h2m4h3m4h4m4h5m4h6m4h7m