Closed cideM closed 2 years ago
I'm able to reproduce this issue on Ubuntu:
cabal build chronos:chronos-test --write-ghc-environment-files=always --enable-tests
cabal build chronos:doctest
/home/amartin/Development/chronos/dist-newstyle/build/x86_64-linux/ghc-8.10.3/chronos-1.1.2/t/doctest/build/doctest/doctest
This fails with the same error you are getting on NixOS. I have no idea why this happens. Also, the doctests are running really slowly, even the ones that succeed. I have no idea why this is failing, but I am inclined to just give up on doctest. It just keeps breaking once or twice every year.
I am able to reproduce in gentoo.
ghc-8.10.3
base-4.14.1.0
chronos-1.1.1
, revision 1 (from hackage)In 7bbd0a849b1ab541b53b3e876b7738758f141dfa, I have introduced a change that fixes this. I believe that it should work on gentoo now. I'm not sure about nix since it requires having doctest
on the path, but perhaps the readme could be updated to explain how to make this work with nix. But the original issue will now be moot since nixpkgs will not try to run the doctests.
Marking this issue as closed since I think this should not cause any trouble any more. Open a new issue if it is possible to reproduce with chonos-1.1.4
or later.
I'm trying to figure out why
chronos
doesn't build in Nixpkgs. So I cloned the repository and the ran the commands fromappveyor.yml
but this gives me the following rather long list of errors
errors
``` Test suite doctest: RUNNING... ld: warning: /nix/store/hxcwxf1bhx8dhlyzjyzcgpw91b66cnrw-libiconv-osx-10.12.6/lib/libiconv.dylib, ignoring unexpected dylib file src/Chronos.hs:404: failure in expression `\(d :: Datetime) -> timeToDatetime (datetimeToTime d) == d'which is also what Nixpkgs has problems with.
The issue does not happen on my NixOS machine which is using ghc 8.8.4. If I switch GHC on MacOS
it also passes on that machine.
Let me know if you need more information