-
-
Notifications
You must be signed in to change notification settings - Fork 49
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
doctests hang when compiling with nix #15
Comments
…te-packages. The doctests for termonad fail to build only with nix. When building without nix, the doctests run correctly: cdepillabout/termonad#15 This PR disables the tests for termonad, as well as removing it from dont-distribute-packages.
…te-packages. The doctests for termonad fail to build only with nix. When building without nix, the doctests run correctly: cdepillabout/termonad#15 This PR disables the tests for termonad, as well as removing it from dont-distribute-packages.
…te-packages. The doctests for termonad fail to build only with nix. When building without nix, the doctests run correctly: cdepillabout/termonad#15 This PR disables the tests for termonad, as well as removing it from dont-distribute-packages.
|
I've figured out that this seems to be caused the by the configure options declared in the generic Haskell builder: Commenting out all those options appears to make the doctests succeed in just a minute or two. I'm currently trying to figure out which option is to blame. |
I figured this out and posted sent a PR about it upstream: |
This appears to be the corresponding GHC issue: |
I finally fixed this in #113. |
I'm encountering this issue while trying to build the latest version of Termonad on Nixos 19.03, with the following Nixos configuration: { config, pkgs, ... }:
let
termonad = builtins.fetchGit {
url = "https://github.com/cdepillabout/termonad";
ref = "master";
};
in
{
environment.systemPackages = with pkgs; [
(import "${termonad}/.nix-helpers/termonad-with-packages.nix" { })
];
} As described, the doctest run takes 100% and eventually gets OOM-killed. For now I'm bypassing the issue by disabling tests: { config, pkgs, ... }:
let
termonad = builtins.fetchGit {
url = "https://github.com/cdepillabout/termonad";
ref = "master";
};
additionalOverlays = [
(self: super: {
haskell = super.haskell // {
packageOverrides = hself: hsuper:
super.haskell.packageOverrides hself hsuper // {
termonad = self.haskell.lib.dontCheck hsuper.termonad;
};
};
})
];
in
{
environment.systemPackages = with pkgs; [
(import "${termonad}/.nix-helpers/termonad-with-packages.nix" { inherit additionalOverlays; })
];
} Is this expected? Is the fix you referenced only applicable for 19.09? Thanks. |
@n4074 Thanks for this report. However, I just tried compiling this and running the doctests at the current HEAD of
In this setup, you are basically pulling the I'm not sure what could be causing any difference here. However, if you can't figure out what could be going on, maybe you'd like to send a PR adding a top-level option to |
Another thing you could try doing is just getting termonad from a recent release of nixpkgs. Here is nixpkgs-unstable as of today: $ cd /some/path/to/nixpkgs
$ git checkout master
$ git pull
$ nix repl ./.
> termonad-with-packages
«derivation /nix/store/gnil59dy229r729g6x8izzl9hsa4pml0-termonad-with-packages-8.6.5.drv»
> haskellPackages.termonad
«derivation /nix/store/99py0xvjjpgdcgj03ks160kyfd7mp266-termonad-2.0.0.0.drv» The top-level |
Thanks for your response @cdepillabout . When I upped the RAM on the VM from 4GB to 8GB the doctests started finishing reasonably quickly. I guess it just uses a lot more memory than expected. |
The doctests for termonad appear to hang when compiling with
nix-build
. Because of this I have disabled them in thetermonad.nix
file.Here is what it looks like when running
nix-build
:It just hangs here.
doctest
appears to fork multiple threads and use 100% of the CPU, but nothing seems to happen.The doctests work when run with
stack
, even on NixOS.The text was updated successfully, but these errors were encountered: