stack v1.3.0 Release Notes

  • ๐Ÿš€ Release notes:

    • For the next stack release after this one, we are planning changes to our Linux releases, including dropping our Ubuntu, Debian, CentOS, and Fedora package repositories and switching to statically linked binaries. See #2534. Note that upgrading without a package manager has gotten easier with new binary upgrade support in stack upgrade (see the Major Changes section below for more information). In addition, the get.haskellstack.org script no longer installs from Ubuntu, Debian, CentOS, or Fedora package repositories. Instead it places a generic binary in /usr/local/bin.

    Major changes:

    • Stack will now always use its own GHC installation, even when a suitable GHC installation is available on the PATH. To get the old behaviour, use the --system-ghc flag or run stack config set system-ghc --global true. Docker- and Nix-enabled projects continue to use the GHC installations in their environment by default.

      NB: Scripts that previously used stack in combination with a system GHC installation should now include a stack setup line or use the --install-ghc flag. #2221

    • ๐Ÿ— stack ghci now defaults to skipping the build of target packages, because support has been added for invoking "initial build steps", which create autogen files and run preprocessors. The --no-build flag is now deprecated because it should no longer be necessary. See #1364

    • โฌ†๏ธ Stack is now capable of doing binary upgrades instead of always recompiling a new version from source. Running stack upgrade will now default to downloading a binary version of Stack from the most recent release, if one is available. See stack upgrade --help for more options. #1238

    Behavior changes:

    • Passing --resolver X with a Stack command which forces creation of a global project config, will pass resolver X into the initial config. See #2579.

    • Switch the "Run from outside project" messages to debug-level, to avoid spamming users in the normal case of non-project usage

    • ๐Ÿ“ฆ If a remote package is specified (such as a Git repo) without an explicit extra-dep setting, a warning is given to the user to provide one explicitly.

    Other enhancements:

    • ๐Ÿ‘€ stack haddock now supports --haddock-internal. See #2229
    • โž• Add support for system-ghc and install-ghc fields to stack config set command.
    • โž• Add ghc-build option to override autodetected GHC build to use (e.g. gmp4, tinfo6, nopie) on Linux.
    • 0๏ธโƒฃ stack setup detects systems where gcc enables PIE by default (such as Ubuntu 16.10 and Hardened Gentoo) and adjusts the GHC configure options accordingly. #2542
    • Upload to Hackage with HTTP digest instead of HTTP basic.
    • ๐Ÿ‘‰ Make stack list-dependencies understand all of the stack dot options too.
    • โž• Add the ability for stack list-dependencies to list dependency licenses by passing the --license flag.
    • ๐Ÿ“ฆ Dump logs that contain warnings for any local non-dependency packages #2545
    • โž• Add the dump-logs config option and --dump-logs command line option to get full build output on the console. #426
    • โž• Add the --open option to "stack hpc report" command, causing the report to be opened in the browser.
    • The stack config set command now accepts a --global flag for suitable fields which causes it to modify the global user configuration (~/.stack/config.yaml) instead of the project configuration. #2675
    • โœ… Information on the latest available snapshots is now downloaded from S3 instead of stackage.org, increasing reliability in case of stackage.org outages. #2653
    • stack dot and stack list-dependencies now take targets and flags. #1919
    • ๐Ÿ—„ Deprecate stack setup --stack-setup-yaml for --setup-info-yaml based on discussion in #2647.
    • The --main-is flag for GHCI now implies the TARGET, fixing #1845.
    • ๐Ÿ— stack ghci no longer takes all build options, as many weren't useful #2199
    • ๐Ÿ”Š --no-time-in-log option, to make verbose logs more diffable #2727
    • ๐Ÿ‘ --color option added to override auto-detection of ANSI support #2725
    • Missing extra-deps are now warned about, adding a degree of typo detection #1521
    • ๐Ÿ— No longer warns about missing build-tools if they are on the PATH. #2235
    • Replace enclosed-exceptions with safe-exceptions. #2768
    • ๐Ÿ”ง The install location for GHC and other programs can now be configured with the local-programs-path option in config.yaml. #1644
    • โž• Added option to add nix dependencies as nix GC roots
    • ๐Ÿณ Proper pid 1 (init) process for stack exec with Docker
    • ๐Ÿ— Dump build logs if they contain warnings. #2545
    • ๐Ÿณ Docker: redirect stdout of docker pull to stderr so that it will not interfere with output of other commands.
    • ๐Ÿณ Nix & docker can be activated at the same time, in order to run stack in a nix-shell in a container, preferably from an image already containing the nix dependencies in its /nix/store
    • ๐Ÿšš Stack/nix: Dependencies can be added as nix GC roots, so they are not removed when running nix-collect-garbage

    ๐Ÿ› Bug fixes:

    • ๐Ÿ›  Fixed a gnarly bug where programs and package tarballs sometimes have corrupted downloads. See #2657.
    • โž• Add proper support for non-ASCII characters in file paths for the sdist command. See #2549
    • ๐Ÿ“ฆ Never treat extra-dep local packages as targets. This ensures things like test suites are not run for these packages, and that build output is not hidden due to their presence.
    • ๐Ÿ›  Fix a resource leak in sinkProcessStderrStdout which could affect much of the codebase, in particular copying precompiled packages. #1979
    • ๐Ÿณ Docker: ensure that interrupted extraction process does not cause corrupt file when downloading a Docker-compatible Stack executable #2568
    • ๐Ÿ›  Fixed running stack hpc report on package targets. #2664
    • ๐Ÿ›  Fix a long-standing performance regression where stack would parse the .dump-hi files of the library components of local packages twice. #2658
    • ๐Ÿ›  Fixed a regression in "stack ghci --no-load", where it would prompt for a main module to load. #2603
    • ๐Ÿ— Build Setup.hs files with the threaded RTS, mirroring the behavior of cabal-install and enabling more complex build systems in those files.
    • ๐Ÿ›  Fixed a bug in passing along --ghc-options to ghcjs. They were being provided as --ghc-options to Cabal, when it needs to be --ghcjs-options. #2714
    • ๐Ÿณ Launch Docker from the project root regardless of the working directory Stack is invoked from. This means paths relative to the project root (e.g. environment files) can be specified in stack.yaml's docker run-args.
    • stack setup --reinstall now behaves as expected. #2554