Skip to content

Commit c0982a4

Browse files
committed
v1.3.1.1: Allow network-3.2 and time-1.14; bump CI to GHC 9.10
1 parent b9c3e2a commit c0982a4

File tree

4 files changed

+55
-44
lines changed

4 files changed

+55
-44
lines changed

.github/workflows/haskell-ci.yml

Lines changed: 39 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -8,9 +8,9 @@
88
#
99
# For more information, see https://github.com/andreasabel/haskell-ci
1010
#
11-
# version: 0.17.20231112
11+
# version: 0.19.20240403
1212
#
13-
# REGENDATA ("0.17.20231112",["github","hslogger.cabal"])
13+
# REGENDATA ("0.19.20240403",["github","hslogger.cabal"])
1414
#
1515
name: Haskell-CI
1616
on:
@@ -32,14 +32,19 @@ jobs:
3232
strategy:
3333
matrix:
3434
include:
35-
- compiler: ghc-9.8.1
35+
- compiler: ghc-9.10.0.20240328
3636
compilerKind: ghc
37-
compilerVersion: 9.8.1
37+
compilerVersion: 9.10.0.20240328
3838
setup-method: ghcup
3939
allow-failure: false
40-
- compiler: ghc-9.6.3
40+
- compiler: ghc-9.8.2
4141
compilerKind: ghc
42-
compilerVersion: 9.6.3
42+
compilerVersion: 9.8.2
43+
setup-method: ghcup
44+
allow-failure: false
45+
- compiler: ghc-9.6.4
46+
compilerKind: ghc
47+
compilerVersion: 9.6.4
4348
setup-method: ghcup
4449
allow-failure: false
4550
- compiler: ghc-9.4.8
@@ -96,8 +101,9 @@ jobs:
96101
mkdir -p "$HOME/.ghcup/bin"
97102
curl -sL https://downloads.haskell.org/ghcup/0.1.20.0/x86_64-linux-ghcup-0.1.20.0 > "$HOME/.ghcup/bin/ghcup"
98103
chmod a+x "$HOME/.ghcup/bin/ghcup"
104+
"$HOME/.ghcup/bin/ghcup" config add-release-channel https://raw.githubusercontent.com/haskell/ghcup-metadata/master/ghcup-prereleases-0.0.8.yaml;
99105
"$HOME/.ghcup/bin/ghcup" install ghc "$HCVER" || (cat "$HOME"/.ghcup/logs/*.* && false)
100-
"$HOME/.ghcup/bin/ghcup" install cabal 3.10.2.0 || (cat "$HOME"/.ghcup/logs/*.* && false)
106+
"$HOME/.ghcup/bin/ghcup" install cabal 3.10.3.0 || (cat "$HOME"/.ghcup/logs/*.* && false)
101107
env:
102108
HCKIND: ${{ matrix.compilerKind }}
103109
HCNAME: ${{ matrix.compiler }}
@@ -115,12 +121,12 @@ jobs:
115121
echo "HC=$HC" >> "$GITHUB_ENV"
116122
echo "HCPKG=$HCPKG" >> "$GITHUB_ENV"
117123
echo "HADDOCK=$HADDOCK" >> "$GITHUB_ENV"
118-
echo "CABAL=$HOME/.ghcup/bin/cabal-3.10.2.0 -vnormal+nowrap" >> "$GITHUB_ENV"
124+
echo "CABAL=$HOME/.ghcup/bin/cabal-3.10.3.0 -vnormal+nowrap" >> "$GITHUB_ENV"
119125
HCNUMVER=$(${HC} --numeric-version|perl -ne '/^(\d+)\.(\d+)\.(\d+)(\.(\d+))?$/; print(10000 * $1 + 100 * $2 + ($3 == 0 ? $5 != 1 : $3))')
120126
echo "HCNUMVER=$HCNUMVER" >> "$GITHUB_ENV"
121127
echo "ARG_TESTS=--enable-tests" >> "$GITHUB_ENV"
122128
echo "ARG_BENCH=--enable-benchmarks" >> "$GITHUB_ENV"
123-
echo "HEADHACKAGE=false" >> "$GITHUB_ENV"
129+
if [ $((HCNUMVER >= 91000)) -ne 0 ] ; then echo "HEADHACKAGE=true" >> "$GITHUB_ENV" ; else echo "HEADHACKAGE=false" >> "$GITHUB_ENV" ; fi
124130
echo "ARG_COMPILER=--$HCKIND --with-compiler=$HC" >> "$GITHUB_ENV"
125131
echo "GHCJSARITH=0" >> "$GITHUB_ENV"
126132
env:
@@ -149,6 +155,18 @@ jobs:
149155
repository hackage.haskell.org
150156
url: http://hackage.haskell.org/
151157
EOF
158+
if $HEADHACKAGE; then
159+
cat >> $CABAL_CONFIG <<EOF
160+
repository head.hackage.ghc.haskell.org
161+
url: https://ghc.gitlab.haskell.org/head.hackage/
162+
secure: True
163+
root-keys: 7541f32a4ccca4f97aea3b22f5e593ba2c0267546016b992dfadcd2fe944e55d
164+
26021a13b401500c8eb2761ca95c61f2d625bfef951b939a8124ed12ecf07329
165+
f76d08be13e9a61a377a85e2fb63f4c5435d40f8feb3e12eb05905edb8cdea89
166+
key-threshold: 3
167+
active-repositories: hackage.haskell.org, head.hackage.ghc.haskell.org:override
168+
EOF
169+
fi
152170
cat >> $CABAL_CONFIG <<EOF
153171
program-default-options
154172
ghc-options: $GHCJOBS +RTS -M3G -RTS
@@ -199,9 +217,11 @@ jobs:
199217
if [ $((HCNUMVER >= 80200)) -ne 0 ] ; then echo "package hslogger" >> cabal.project ; fi
200218
if [ $((HCNUMVER >= 80200)) -ne 0 ] ; then echo " ghc-options: -Werror=missing-methods" >> cabal.project ; fi
201219
cat >> cabal.project <<EOF
202-
allow-newer: bytestring
203-
allow-newer: containers
220+
allow-newer: network
204221
EOF
222+
if $HEADHACKAGE; then
223+
echo "allow-newer: $($HCPKG list --simple-output | sed -E 's/([a-zA-Z-]+)-[0-9.]+/*:\1,/g')" >> cabal.project
224+
fi
205225
$HCPKG list --simple-output --names-only | perl -ne 'for (split /\s+/) { print "constraints: $_ installed\n" unless /^(hslogger)$/; }' >> cabal.project.local
206226
cat cabal.project
207227
cat cabal.project.local
@@ -210,7 +230,7 @@ jobs:
210230
$CABAL v2-build $ARG_COMPILER $ARG_TESTS $ARG_BENCH --dry-run all
211231
cabal-plan
212232
- name: restore cache
213-
uses: actions/cache/restore@v3
233+
uses: actions/cache/restore@v4
214234
with:
215235
key: ${{ runner.os }}-${{ matrix.compiler }}-${{ github.sha }}
216236
path: ~/.cabal/store
@@ -242,22 +262,15 @@ jobs:
242262
- name: prepare for constraint sets
243263
run: |
244264
rm -f cabal.project.local
245-
- name: constraint set containers-0.7
246-
run: |
247-
if [ $((HCNUMVER >= 80200 && HCNUMVER < 90800)) -ne 0 ] ; then $CABAL v2-build $ARG_COMPILER --enable-tests --disable-benchmarks --constraint='containers ^>= 0.7' all --dry-run ; fi
248-
if [ $((HCNUMVER >= 80200 && HCNUMVER < 90800)) -ne 0 ] ; then cabal-plan topo | sort ; fi
249-
if [ $((HCNUMVER >= 80200 && HCNUMVER < 90800)) -ne 0 ] ; then $CABAL v2-build $ARG_COMPILER --enable-tests --disable-benchmarks --constraint='containers ^>= 0.7' --dependencies-only -j2 all ; fi
250-
if [ $((HCNUMVER >= 80200 && HCNUMVER < 90800)) -ne 0 ] ; then $CABAL v2-build $ARG_COMPILER --enable-tests --disable-benchmarks --constraint='containers ^>= 0.7' all ; fi
251-
if [ $((HCNUMVER >= 80200 && HCNUMVER < 90800)) -ne 0 ] ; then $CABAL v2-test $ARG_COMPILER --enable-tests --disable-benchmarks --constraint='containers ^>= 0.7' all ; fi
252-
- name: constraint set bytestring-0.12
265+
- name: constraint set network-3.2
253266
run: |
254-
if [ $((HCNUMVER >= 80200)) -ne 0 ] ; then $CABAL v2-build $ARG_COMPILER --enable-tests --disable-benchmarks --constraint='bytestring ^>= 0.12' all --dry-run ; fi
255-
if [ $((HCNUMVER >= 80200)) -ne 0 ] ; then cabal-plan topo | sort ; fi
256-
if [ $((HCNUMVER >= 80200)) -ne 0 ] ; then $CABAL v2-build $ARG_COMPILER --enable-tests --disable-benchmarks --constraint='bytestring ^>= 0.12' --dependencies-only -j2 all ; fi
257-
if [ $((HCNUMVER >= 80200)) -ne 0 ] ; then $CABAL v2-build $ARG_COMPILER --enable-tests --disable-benchmarks --constraint='bytestring ^>= 0.12' all ; fi
258-
if [ $((HCNUMVER >= 80200)) -ne 0 ] ; then $CABAL v2-test $ARG_COMPILER --enable-tests --disable-benchmarks --constraint='bytestring ^>= 0.12' all ; fi
267+
$CABAL v2-build $ARG_COMPILER --enable-tests --disable-benchmarks --constraint='network ^>= 3.2.0.0' all --dry-run
268+
cabal-plan topo | sort
269+
$CABAL v2-build $ARG_COMPILER --enable-tests --disable-benchmarks --constraint='network ^>= 3.2.0.0' --dependencies-only -j2 all
270+
$CABAL v2-build $ARG_COMPILER --enable-tests --disable-benchmarks --constraint='network ^>= 3.2.0.0' all
271+
$CABAL v2-test $ARG_COMPILER --enable-tests --disable-benchmarks --constraint='network ^>= 3.2.0.0' all
259272
- name: save cache
260-
uses: actions/cache/save@v3
273+
uses: actions/cache/save@v4
261274
if: always()
262275
with:
263276
key: ${{ runner.os }}-${{ matrix.compiler }}-${{ github.sha }}

CHANGELOG.md

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,11 @@
11
See also https://pvp.haskell.org/faq
22

3-
#### 1.3.1.0 *(minor)*
3+
#### 1.3.1.1 *(patch)*
4+
5+
- Drop support for GHC 7
6+
- Tested with GHC 8.0 - 9.10
7+
8+
### 1.3.1.0 *(minor)*
49

510
- Evaluate message before taking lock in simple handler ([#49](https://github.com/haskell-hvr/hslogger/pull/49))
611
- Define `Typeable`, `Data`, `Generic` and `NFData` instances for `System.Log.Priority` ([#43](https://github.com/haskell-hvr/hslogger/pull/43))

cabal.haskell-ci

Lines changed: 4 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,10 @@
11
branches: master
22

3-
constraint-set bytestring-0.12
4-
ghc: >= 8.2
5-
constraints: bytestring ^>= 0.12
6-
tests: True
7-
run-tests: True
8-
9-
constraint-set containers-0.7
10-
ghc: >= 8.2 && < 9.7
11-
constraints: containers ^>= 0.7
3+
constraint-set network-3.2
4+
ghc: >= 8.0
5+
constraints: network ^>= 3.2.0.0
126
tests: True
137
run-tests: True
148

159
raw-project
16-
allow-newer: bytestring
17-
allow-newer: containers
10+
allow-newer: network

hslogger.cabal

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,7 @@
11
cabal-version: 1.12
22
build-type: Simple
33
name: hslogger
4-
version: 1.3.1.0
5-
x-revision: 9
4+
version: 1.3.1.1
65

76
maintainer: https://github.com/haskell-hvr/hslogger
87
author: John Goerzen
@@ -36,8 +35,9 @@ extra-source-files:
3635
testsrc/runtests.hs
3736

3837
tested-with:
39-
GHC == 9.8.1
40-
GHC == 9.6.3
38+
GHC == 9.10.0
39+
GHC == 9.8.2
40+
GHC == 9.6.4
4141
GHC == 9.4.8
4242
GHC == 9.2.8
4343
GHC == 9.0.2
@@ -79,12 +79,12 @@ library
7979
, bytestring >= 0.9 && < 0.13
8080
, containers >= 0.4 && < 0.8
8181
, deepseq >= 1.1 && < 1.6
82-
, time >= 1.2 && < 1.13
82+
, time >= 1.2 && < 1.15
8383
, old-locale >= 1.0 && < 1.1
8484

8585
if flag(network--GT-3_0_0)
8686
build-depends: network-bsd >= 2.8.1 && <2.9,
87-
network >= 3.0 && <3.2
87+
network >= 3.0 && <3.3
8888
else
8989
build-depends: network >= 2.6 && <2.9
9090

0 commit comments

Comments
 (0)