From f90d059e61c5a8ac22a48f7663f4c5f945298ccf Mon Sep 17 00:00:00 2001 From: Javier Sagredo Date: Wed, 28 Aug 2024 13:48:53 +0200 Subject: [PATCH] Re-enable Windows CI (cherry picked from commit 4aade2d8a17704cfcb2fa6cf9fb59478c17a0653) --- .github/workflows/validate.yml | 4 ++++ validate.sh | 3 +++ 2 files changed, 7 insertions(+) diff --git a/.github/workflows/validate.yml b/.github/workflows/validate.yml index dd3f350db3a..00a22ad7c32 100644 --- a/.github/workflows/validate.yml +++ b/.github/workflows/validate.yml @@ -72,6 +72,10 @@ jobs: # support, so the PR *must* have a changelog entry. ghc: ['9.10.1', '9.8.2', '9.6.4', '9.4.8', '9.2.8', '9.0.2', '8.10.7', '8.8.4', '8.6.5'] exclude: + # Throws fatal "cabal-tests.exe: fd:8: hGetLine: end of file" exception + # even with --io-manager=native + - os: windows-latest + ghc: "9.0.2" # corrupts GHA cache or the fabric of reality itself, see https://github.com/haskell/cabal/issues/8356 - os: windows-latest ghc: '8.10.7' diff --git a/validate.sh b/validate.sh index e6cd603db41..1710cd7e2c8 100755 --- a/validate.sh +++ b/validate.sh @@ -324,6 +324,9 @@ CABAL_TESTSUITE_BDIR="$(pwd)/$BUILDDIR/build/$ARCH/$BASEHC/cabal-testsuite-3" CABALNEWBUILD="${CABAL} build $JOBS -w $HC --builddir=$BUILDDIR --project-file=$PROJECTFILE" CABALLISTBIN="${CABAL} list-bin --builddir=$BUILDDIR --project-file=$PROJECTFILE" +# See https://github.com/haskell/cabal/issues/9571 for why we set this for Windows +RTSOPTS="$([ $ARCH = "x86_64-windows" ] && [ "$($HC --numeric-version)" != "9.0.2" ] && [ "$(echo -e "$(ghc --numeric-version)\n9.0.2" | sort -V | head -n1)" = "9.0.2" ] && echo "+RTS --io-manager=native" || echo "")" + # header #######################################################################