When obtained from Hackage, the benchmarks fail to run:
$ cabal get hledger
Unpacking to hledger-0.27/
$ cd hledger-0.27/
$ cabal bench
Running 1 benchmarks...
Benchmark bench: RUNNING...
Benchmarking hledger in /home/ryanglscott/Documents/Hacking/Haskell/hledger-0.27 with timeit
The hledger journal file "bench/10000x1000x10.journal" was not found.
Please create it first, eg with "hledger add" or a text editor.
Or, specify an existing journal file with -f or LEDGER_FILE.
read bench/10000x1000x10.journal Benchmark bench: ERROR
See also iu-parfunc/sc-haskell#7
Thanks for the report. hledger-0.27 was missing this file. This will be resolved fairly soon by the next hledger release, is this sufficient ?
Out of curiosity, where in hledger.cabal is bench/10000x1000x10.journal listed? I don't see it in either extra-source-files or data-files.
add missing benchmark file to cabal tarball (#342)
You're absolutely right! I seem to have a blind spot for these. Should be fixed now.
OK. I tried compiling from HEAD as if it were on Hackage, but I ran into another issue:
$ git clone https://github.com/simonmichael/hledger
$ cd hledger/hledger
$ cabal sdist
$ cd dist/
$ tar -xvf hledger-0.27.tar.gz
$ cabal install --enable-benchmarks
Failed to install hledger-0.27
Build log ( /home/ryanglscott/.cabal/logs/hledger-0.27.log ):
Preprocessing library hledger-0.27...
[ 1 of 21] Compiling Text.Tabular.AsciiWide ( Text/Tabular/AsciiWide.hs, dist/build/Text/Tabular/AsciiWide.o )
[ 2 of 21] Compiling Hledger.Cli.Version ( Hledger/Cli/Version.hs, dist/build/Hledger/Cli/Version.o )
[ 3 of 21] Compiling Hledger.Cli.DocFiles ( Hledger/Cli/DocFiles.hs, dist/build/Hledger/Cli/DocFiles.o )
Exception when trying to run compile-time code:
/home/ryanglscott/Documents/Hacking/Haskell/hledger/hledger/dist/hledger-0.27/../hledger-ui/doc/hledger-ui.1: openFile: does not exist (No such file or directory)
In the splice:
cabal: Error: some packages failed to install:
hledger-0.27 failed during the building phase. The exception was:
Thank you, I've opened #343 for this.
There we go - cabal bench now runs to completion without issue.