From 2be61d8184e31c0fcf443919d4fc22b4b392a553 Mon Sep 17 00:00:00 2001 From: Adithya Kumar Date: Sat, 27 Apr 2024 16:36:53 +0530 Subject: [PATCH 1/9] Update the runner in the CI file --- .github/workflows/haskell.yml | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/.github/workflows/haskell.yml b/.github/workflows/haskell.yml index 953bf39..77c171e 100644 --- a/.github/workflows/haskell.yml +++ b/.github/workflows/haskell.yml @@ -32,8 +32,7 @@ jobs: DISABLE_TEST: "y" DISABLE_BENCH: "y" - # XXX macos? - runs-on: macos-latest + runs-on: ${{ matrix.runner }} strategy: fail-fast: false matrix: From d6c06d0c451fefb6da067980f1675abf7c8d23d0 Mon Sep 17 00:00:00 2001 From: Adithya Kumar Date: Mon, 29 Apr 2024 22:53:20 +0530 Subject: [PATCH 2/9] Update the packcheck github commit in all the CIs --- .circleci/config.yml | 2 +- .github/workflows/haskell.yml | 2 +- appveyor.yml | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 0763ac6..9f6ab6a 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -57,7 +57,7 @@ env: &env # If you have not committed packcheck.sh in your repo at PACKCHECK # then it is automatically pulled from this URL. PACKCHECK_GITHUB_URL: "https://raw.githubusercontent.com/composewell/packcheck" - PACKCHECK_GITHUB_COMMIT: "v0.7.0" + PACKCHECK_GITHUB_COMMIT: "101c73b53473ddfb763d65058b80123991cfeb4f" # image is a tag from docker registery executors: diff --git a/.github/workflows/haskell.yml b/.github/workflows/haskell.yml index 77c171e..6f1809b 100644 --- a/.github/workflows/haskell.yml +++ b/.github/workflows/haskell.yml @@ -20,7 +20,7 @@ jobs: PACKCHECK: "./packcheck.sh" PACKCHECK_GITHUB_URL: "https://raw.githubusercontent.com/composewell/packcheck" - PACKCHECK_GITHUB_COMMIT: "v0.7.0" + PACKCHECK_GITHUB_COMMIT: "101c73b53473ddfb763d65058b80123991cfeb4f" BUILD: ${{ matrix.build }} GHCUPVER: 0.1.20.0 diff --git a/appveyor.yml b/appveyor.yml index de2aea4..2316066 100644 --- a/appveyor.yml +++ b/appveyor.yml @@ -64,7 +64,7 @@ environment: # If you have not committed packcheck.sh in your repo at PACKCHECK_LOCAL_PATH # then it is automatically pulled from this URL. PACKCHECK_GITHUB_URL: "https://raw.githubusercontent.com/harendra-kumar/packcheck" - PACKCHECK_GITHUB_COMMIT: "a68b7b9c7c21eef8ed273e67030efb1d4fec027c" + PACKCHECK_GITHUB_COMMIT: "101c73b53473ddfb763d65058b80123991cfeb4f" # Override the temp directory to avoid sed escaping issues # See https://github.com/haskell/cabal/issues/5386 From 51a1ca53d5bc4dc60557b9106c66e2bf1a0f1ebc Mon Sep 17 00:00:00 2001 From: Adithya Kumar Date: Mon, 29 Apr 2024 23:04:20 +0530 Subject: [PATCH 3/9] Fix env variables in the CI - GHCUP_VERSION - HLINT_VERSION --- .circleci/config.yml | 6 +++--- .github/workflows/haskell.yml | 9 +++------ 2 files changed, 6 insertions(+), 9 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 9f6ab6a..cf4dab2 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -11,7 +11,7 @@ env: &env # Common options # ------------------------------------------------------------------------ # GHC_OPTIONS: "-Werror" - GHCUPVER: 0.1.20.0 + GHCUP_VERSION: 0.1.20.0 CABAL_REINIT_CONFIG: "y" LC_ALL: "C.UTF-8" @@ -94,7 +94,7 @@ preinstall: &preinstall apt-get install -y zlib1g-dev # For ghcup to install ghc - if test -n "$GHCUPVER" + if test -n "$GHCUP_VERSION" then apt-get install -y gcc apt-get install -y g++ @@ -244,7 +244,7 @@ jobs: - run: name: Hlint examples environment: - HLINTVER: 3.6.1 + HLINT_VERSION: 3.6.1 HLINT_OPTIONS: lint HLINT_TARGETS: examples command: | diff --git a/.github/workflows/haskell.yml b/.github/workflows/haskell.yml index 6f1809b..7de6dfa 100644 --- a/.github/workflows/haskell.yml +++ b/.github/workflows/haskell.yml @@ -16,21 +16,21 @@ jobs: STACK_UPGRADE: "y" CABAL_CHECK_RELAX: y - CABAL_NO_SANDBOX: y PACKCHECK: "./packcheck.sh" PACKCHECK_GITHUB_URL: "https://raw.githubusercontent.com/composewell/packcheck" PACKCHECK_GITHUB_COMMIT: "101c73b53473ddfb763d65058b80123991cfeb4f" BUILD: ${{ matrix.build }} - GHCUPVER: 0.1.20.0 + GHCUP_VERSION: 0.1.20.0 GHCVER: ${{ matrix.ghc_version }} CABALVER: ${{ matrix.cabal_version }} CABAL_BUILD_OPTIONS: ${{ matrix.cabal_build_options }} CABAL_PROJECT: ${{ matrix.cabal_project }} - DISABLE_DOCS: ${{ matrix.disable_docs }} + DISABLE_DOCS: "y" DISABLE_TEST: "y" DISABLE_BENCH: "y" + DISABLE_SDIST_BUILD: ${{ matrix.disable_sdist_build }} runs-on: ${{ matrix.runner }} strategy: @@ -43,7 +43,6 @@ jobs: build: cabal cabal_project: cabal.project.user cabal_version: 3.8.1.0 - disable_docs: "y" disable_sdist_build: "y" ignore_error: false - name: 9.2.7 @@ -52,7 +51,6 @@ jobs: build: cabal cabal_project: cabal.project.user cabal_version: 3.6.2.0 - disable_docs: "y" disable_sdist_build: "y" ignore_error: false - name: 8.10.7+macOS @@ -61,7 +59,6 @@ jobs: build: cabal cabal_project: cabal.project.user cabal_version: 3.6.2.0 - disable_docs: "y" cabal_build_options: "--flag interop" ignore_error: false steps: From ecf2741d04859ed0451ff500ac047fd82945e589 Mon Sep 17 00:00:00 2001 From: Adithya Kumar Date: Mon, 29 Apr 2024 23:12:09 +0530 Subject: [PATCH 4/9] Update streamly version constraints to bleeding-egde --- streamly-examples.cabal | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/streamly-examples.cabal b/streamly-examples.cabal index 144adf1..34e035c 100644 --- a/streamly-examples.cabal +++ b/streamly-examples.cabal @@ -60,8 +60,8 @@ flag interop common exe-dependencies build-depends: - streamly == 0.10.0 - , streamly-core == 0.2.0 + streamly == 0.11.0 + , streamly-core == 0.3.0 , base >= 4.9 && < 4.20 , directory >= 1.2 && < 1.4 , transformers >= 0.4 && < 0.7 From fb11b9a835f8acb41d200360979851eb9a6d51b3 Mon Sep 17 00:00:00 2001 From: Adithya Kumar Date: Thu, 2 May 2024 02:21:06 +0530 Subject: [PATCH 5/9] Set DEBIAN_FRONTEND to noninteractive while installing prerequisites --- .circleci/config.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.circleci/config.yml b/.circleci/config.yml index cf4dab2..815ef7e 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -74,6 +74,7 @@ executors: preinstall: &preinstall run: | + export DEBIAN_FRONTEND=noninteractive apt-get update # For sdl build flag apt-get install -y libsdl2-dev From 2bf039dedcea5060b379fc2e8369cdf82772eb8e Mon Sep 17 00:00:00 2001 From: Adithya Kumar Date: Thu, 2 May 2024 02:34:23 +0530 Subject: [PATCH 6/9] Update the stack file --- stack.yaml | 22 ++++++++++++++-------- 1 file changed, 14 insertions(+), 8 deletions(-) diff --git a/stack.yaml b/stack.yaml index 1451a4a..f0ba9bd 100644 --- a/stack.yaml +++ b/stack.yaml @@ -1,20 +1,26 @@ -resolver: nightly-2023-12-14 +resolver: lts-20.13 packages: - '.' extra-deps: +- lockfree-queue-0.2.4 #- streamly-core-0.1.0 #- streamly-0.9.0 #- fusion-plugin-0.2.6 - -# - git: https://github.com/composewell/streamly -# commit: 147750cc437388b276e07f69c25ceb4d1229bcc7 -# - git: https://github.com/composewell/streamly -# commit: 147750cc437388b276e07f69c25ceb4d1229bcc7 -# subdirs: -# - core +- git: https://github.com/composewell/streamly + commit: e4ce30bd6393080397ee52927372f33dcde94d0b +- git: https://github.com/composewell/streamly + commit: e4ce30bd6393080397ee52927372f33dcde94d0b + subdirs: + - core # - lockfree-queue-0.2.4@sha256:156e7ccc193fc5d8b43f065e9cd31c3171c79ec25863283d546900d92930846d,2963 # - tasty-bench-0.3.2@sha256:e7678a19114e1ff5effbe9b96a4688fa085cee39a50003d1170ec271f83e0792,2209 +rebuild-ghc-options: true + # For mac ports installed SDL library on Mac OS X extra-include-dirs: - /opt/local/include + +flags: + mintty: + Win32-2-13-1: false From 0fdae8b5efa1d241154ef446bcd18d67c1ec7246 Mon Sep 17 00:00:00 2001 From: Adithya Kumar Date: Thu, 2 May 2024 02:54:44 +0530 Subject: [PATCH 7/9] Fix Werror build --- examples/CSVParser.hs | 4 ++-- examples/CoreUtilsHandle.hs | 5 ++--- 2 files changed, 4 insertions(+), 5 deletions(-) diff --git a/examples/CSVParser.hs b/examples/CSVParser.hs index 5e5fffd..ceda474 100644 --- a/examples/CSVParser.hs +++ b/examples/CSVParser.hs @@ -13,7 +13,7 @@ import qualified Streamly.Data.Fold as Fold import qualified Streamly.Data.Stream as Stream import qualified Streamly.FileSystem.Handle as Handle import qualified System.IO as IO -import qualified Streamly.Internal.Data.Array.Stream as ArrayStream (splitOn) +import qualified Streamly.Internal.Data.Array as Array (compactOnByte) main :: IO () main = do @@ -21,7 +21,7 @@ main = do src <- IO.openFile inFile ReadMode Handle.readChunks src -- Stream IO (Array Word8) - & ArrayStream.splitOn 10 -- Stream IO (Array Word8) + & Array.compactOnByte 10 -- Stream IO (Array Word8) & Stream.fold (Fold.drainMapM parseLine) -- IO () where diff --git a/examples/CoreUtilsHandle.hs b/examples/CoreUtilsHandle.hs index b2f4185..3c6ac9e 100644 --- a/examples/CoreUtilsHandle.hs +++ b/examples/CoreUtilsHandle.hs @@ -9,8 +9,7 @@ import qualified Streamly.Data.Fold as Fold import qualified Streamly.Data.Stream as Stream import qualified Streamly.FileSystem.Handle as Handle import qualified Streamly.Unicode.Stream as Unicode - -import qualified Streamly.Internal.Data.Array.Stream as ArrayStream (splitOn) +import qualified Streamly.Internal.Data.Array as Array (compactOnByte) -- | Read the contents of a file to stdout. -- @@ -74,7 +73,7 @@ wclChar src = wcl :: Handle -> IO Int wcl src = Handle.readChunks src -- Stream IO (Array Word8) - & ArrayStream.splitOn 10 -- Stream IO (Array Word8) + & Array.compactOnByte 10 -- Stream IO (Array Word8) & Stream.fold Fold.length -- IO () main :: IO () From b67eb9e06f25c94a9f51d45facc751c55603ea0f Mon Sep 17 00:00:00 2001 From: Adithya Kumar Date: Thu, 2 May 2024 13:45:35 +0530 Subject: [PATCH 8/9] Disable macos sdist build --- .github/workflows/haskell.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/haskell.yml b/.github/workflows/haskell.yml index 7de6dfa..32888e0 100644 --- a/.github/workflows/haskell.yml +++ b/.github/workflows/haskell.yml @@ -58,6 +58,7 @@ jobs: runner: macos-latest build: cabal cabal_project: cabal.project.user + disable_sdist_build: "y" cabal_version: 3.6.2.0 cabal_build_options: "--flag interop" ignore_error: false From 48ece47696e36bb7a9ebd85bceb5eada709ea931 Mon Sep 17 00:00:00 2001 From: Adithya Kumar Date: Thu, 2 May 2024 18:38:16 +0530 Subject: [PATCH 9/9] Add new CI builds --- .github/workflows/haskell.yml | 23 ++++++++++++++++++++--- 1 file changed, 20 insertions(+), 3 deletions(-) diff --git a/.github/workflows/haskell.yml b/.github/workflows/haskell.yml index 32888e0..0f1ed3a 100644 --- a/.github/workflows/haskell.yml +++ b/.github/workflows/haskell.yml @@ -37,6 +37,23 @@ jobs: fail-fast: false matrix: include: + - name: 9.8.1 + ghc_version: 9.8.1 + runner: ubuntu-latest + build: cabal + cabal_project: cabal.project.user + cabal_version: 3.10.1.0 + disable_sdist_build: "y" + ignore_error: false + - name: 9.6.3-macos + ghc_version: 9.6.3 + runner: macos-latest + build: cabal + cabal_project: cabal.project.user + disable_sdist_build: "y" + cabal_version: 3.10.1.0 + cabal_build_options: "--flag interop" + ignore_error: false - name: 9.4.4 ghc_version: 9.4.4 runner: ubuntu-latest @@ -53,14 +70,14 @@ jobs: cabal_version: 3.6.2.0 disable_sdist_build: "y" ignore_error: false - - name: 8.10.7+macOS + - name: 8.10.7 # There is some llvm versioning issue in 8.10.7 and the + # mac machine ghc_version: 8.10.7 - runner: macos-latest + runner: ubuntu-latest build: cabal cabal_project: cabal.project.user disable_sdist_build: "y" cabal_version: 3.6.2.0 - cabal_build_options: "--flag interop" ignore_error: false steps: - uses: actions/checkout@v2