on develop help sign in
Merge branch 'develop' into cleanup-debug
711b0b4Oliver Batchelor
.travis.yml+19−30
@@ -4,7 +4,7 @@
4#
4#
5# For more information, see https://github.com/haskell-CI/haskell-ci
5# For more information, see https://github.com/haskell-CI/haskell-ci
6#
6#
7−# version: 0.3.20190804.2
7+# version: 0.3.20190814
8#
8#
9language: c
9language: c
10dist: xenial
10dist: xenial
@@ -25,12 +25,10 @@ before_cache:
25 - rm -fv $CABALHOME/packages/hackage.haskell.org/01-index.tar
25 - rm -fv $CABALHOME/packages/hackage.haskell.org/01-index.tar
26 - rm -fv $CABALHOME/packages/hackage.haskell.org/01-index.tar.idx
26 - rm -fv $CABALHOME/packages/hackage.haskell.org/01-index.tar.idx
27 - rm -rfv $CABALHOME/packages/head.hackage
27 - rm -rfv $CABALHOME/packages/head.hackage
28−
29matrix:
28matrix:
30 include:
29 include:
31 - compiler: ghcjs-8.4
30 - compiler: ghcjs-8.4
32− addons: {"apt":{"sources":["hvr-ghc"],"packages":["ghc-8.4.4","cabal-install-3.0"]}}
31+ addons: {"apt":{"sources":["hvr-ghc"],"packages":["cabal-install-3.0"]}}
33− env: GHCJS_PACKAGE="ghcjs-8.4"
34 - compiler: ghc-8.6.5
32 - compiler: ghc-8.6.5
35 addons: {"apt":{"sources":["hvr-ghc"],"packages":["ghc-8.6.5","cabal-install-2.4"]}}
33 addons: {"apt":{"sources":["hvr-ghc"],"packages":["ghc-8.6.5","cabal-install-2.4"]}}
36 - compiler: ghc-8.4.4
34 - compiler: ghc-8.4.4
@@ -39,18 +37,14 @@ matrix:
39 addons: {"apt":{"sources":["hvr-ghc"],"packages":["ghc-8.2.2","cabal-install-2.4"]}}
37 addons: {"apt":{"sources":["hvr-ghc"],"packages":["ghc-8.2.2","cabal-install-2.4"]}}
40 - compiler: ghc-8.0.2
38 - compiler: ghc-8.0.2
41 addons: {"apt":{"sources":["hvr-ghc"],"packages":["ghc-8.0.2","cabal-install-2.4"]}}
39 addons: {"apt":{"sources":["hvr-ghc"],"packages":["ghc-8.0.2","cabal-install-2.4"]}}
42− allow_failures:
43− - compiler: "ghcjs-8.4" # This hits the travis 50min time limit and fails
44−
45before_install:
40before_install:
46 - |
41 - |
47− if [ "$TRAVIS_OS_NAME" = "linux" ] && [ ! -z "$GHCJS_PACKAGE" ]; then
42+ if [ "$TRAVIS_OS_NAME" = "linux" ]; then
48− curl -s https://deb.nodesource.com/gpgkey/nodesource.gpg.key | sudo apt-key add -;
49− sudo sh -c "echo deb https://deb.nodesource.com/node_8.x xenial main > /etc/apt/sources.list.d/nodesource.list";
50 sudo add-apt-repository -y ppa:hvr/ghcjs;
43 sudo add-apt-repository -y ppa:hvr/ghcjs;
44+ curl -s https://deb.nodesource.com/gpgkey/nodesource.gpg.key | sudo apt-key add -
45+ sudo apt-add-repository 'https://deb.nodesource.com/node_8.x xenial main'
51 sudo apt-get update;
46 sudo apt-get update;
52− sudo apt-get install nodejs;
47+ sudo apt-get install $CC cabal-install-3.0 nodejs;
53− sudo apt-get install "$GHCJS_PACKAGE";
54 fi
48 fi
55 - HC=$(echo "/opt/$CC/bin/ghc" | sed 's/-/\//')
49 - HC=$(echo "/opt/$CC/bin/ghc" | sed 's/-/\//')
56 - WITHCOMPILER="-w $HC"
50 - WITHCOMPILER="-w $HC"
@@ -62,8 +56,8 @@ before_install:
62 else
56 else
63 GHCJS=false;
57 GHCJS=false;
64 fi
58 fi
65− - if $GHCJS ; then sudo apt-get install -y ghc-8.6.5 ; fi
59+ - if $GHCJS ; then sudo apt-get install -y ghc-8.4.4 ; fi
66− - if $GHCJS ; then PATH="/opt/ghc/8.6.5/bin:$PATH" ; fi
60+ - if $GHCJS ; then PATH="/opt/ghc/8.4.4/bin:$PATH" ; fi
67 - HCPKG="$HC-pkg"
61 - HCPKG="$HC-pkg"
68 - unset CC
62 - unset CC
69 - CABAL=/opt/ghc/bin/cabal
63 - CABAL=/opt/ghc/bin/cabal
@@ -99,6 +93,7 @@ install:
99 - echo $GHCJS
93 - echo $GHCJS
100 - TEST=--enable-tests
94 - TEST=--enable-tests
101 - BENCH=--enable-benchmarks
95 - BENCH=--enable-benchmarks
96+ - BENCH=--disable-benchmarks
102 - HEADHACKAGE=false
97 - HEADHACKAGE=false
103 - rm -f $CABALHOME/config
98 - rm -f $CABALHOME/config
104 - |
99 - |
@@ -120,20 +115,19 @@ install:
120 - cat $CABALHOME/config
115 - cat $CABALHOME/config
121 - rm -fv cabal.project cabal.project.local cabal.project.freeze
116 - rm -fv cabal.project cabal.project.local cabal.project.freeze
122 - travis_retry ${CABAL} v2-update -v
117 - travis_retry ${CABAL} v2-update -v
123− - if $GHCJS ; then (cd /tmp && ${CABAL} v2-install -w ghc-8.6.5 happy) ; fi
118+ - if $GHCJS ; then (cd /tmp && ${CABAL} v2-install -w ghc-8.4.4 happy) ; fi
124 # Generate cabal.project
119 # Generate cabal.project
125 - rm -rf cabal.project cabal.project.local cabal.project.freeze
120 - rm -rf cabal.project cabal.project.local cabal.project.freeze
126 - touch cabal.project
121 - touch cabal.project
127 - |
122 - |
128 echo "packages: ." >> cabal.project
123 echo "packages: ." >> cabal.project
124+ - |
129 - cat cabal.project || true
125 - cat cabal.project || true
130 - cat cabal.project.local || true
126 - cat cabal.project.local || true
131 - if [ -f "./configure.ac" ]; then (cd "." && autoreconf -i); fi
127 - if [ -f "./configure.ac" ]; then (cd "." && autoreconf -i); fi
132 - ${CABAL} v2-freeze $WITHCOMPILER ${TEST} ${BENCH} | color_cabal_output
128 - ${CABAL} v2-freeze $WITHCOMPILER ${TEST} ${BENCH} | color_cabal_output
133− - ${CABAL} v2-configure $WITHCOMPILER ${TEST} ${BENCH} | color_cabal_output
134 - "cat cabal.project.freeze | sed -E 's/^(constraints: *| *)//' | sed 's/any.//'"
129 - "cat cabal.project.freeze | sed -E 's/^(constraints: *| *)//' | sed 's/any.//'"
135− - rm cabal.project.freeze || true
130+ - rm cabal.project.freeze
136− - rm cabal.project.local || true
137script:
131script:
138 - DISTDIR=$(mktemp -d /tmp/dist-test.XXXX)
132 - DISTDIR=$(mktemp -d /tmp/dist-test.XXXX)
139 # Packaging...
133 # Packaging...
@@ -152,7 +146,6 @@ script:
152 - |
146 - |
153 - cat cabal.project || true
147 - cat cabal.project || true
154 - cat cabal.project.local || true
148 - cat cabal.project.local || true
155− - rm cabal.project.local || true
156 # Building...
149 # Building...
157 # this builds all libraries and executables (without tests/benchmarks)
150 # this builds all libraries and executables (without tests/benchmarks)
158 - ${CABAL} v2-build $WITHCOMPILER --disable-tests --disable-benchmarks all | color_cabal_output
151 - ${CABAL} v2-build $WITHCOMPILER --disable-tests --disable-benchmarks all | color_cabal_output
@@ -160,23 +153,19 @@ script:
160 # build & run tests, build benchmarks
153 # build & run tests, build benchmarks
161 - ${CABAL} v2-build $WITHCOMPILER ${TEST} ${BENCH} all | color_cabal_output
154 - ${CABAL} v2-build $WITHCOMPILER ${TEST} ${BENCH} all | color_cabal_output
162 # Testing...
155 # Testing...
163− - if ! $GHCJS && [ $HCNUMVER -ge 80000 ] && [ $HCNUMVER -lt 80606 ] ; then ${CABAL} v2-test $WITHCOMPILER ${TEST} ${BENCH} all | color_cabal_output ; fi
156+ - if ! $GHCJS ; then ${CABAL} v2-test $WITHCOMPILER ${TEST} ${BENCH} all | color_cabal_output ; fi
164 # cabal check...
157 # cabal check...
165 - (cd ${PKGDIR_reflex} && ${CABAL} -vnormal check)
158 - (cd ${PKGDIR_reflex} && ${CABAL} -vnormal check)
166 # haddock...
159 # haddock...
167− - if ! $GHCJS && [ $HCNUMVER -ge 80000 ] && [ $HCNUMVER -lt 80606 ] ; then ${CABAL} v2-haddock $WITHCOMPILER ${TEST} ${BENCH} all | color_cabal_output ; fi
160+ - if ! $GHCJS ; then ${CABAL} v2-haddock $WITHCOMPILER ${TEST} ${BENCH} all | color_cabal_output ; fi
168− # Building without installed constraints for packages in global-db...
169− - rm -f cabal.project.local || true
170− - ${CABAL} v2-build $WITHCOMPILER --disable-tests --disable-benchmarks all | color_cabal_output
171 # Constraint sets
161 # Constraint sets
172− - rm -rf cabal.project.local || true
162+ - rm -rf cabal.project.local
173 # Constraint set no-th
163 # Constraint set no-th
174 - ${CABAL} v2-build $WITHCOMPILER --disable-tests --disable-benchmarks --constraint='reflex -use-template-haskell' all | color_cabal_output
164 - ${CABAL} v2-build $WITHCOMPILER --disable-tests --disable-benchmarks --constraint='reflex -use-template-haskell' all | color_cabal_output
175− # Constraint sets
165+ # Constraint set old-these
176− - rm -rf cabal.project.local || true
166+ - ${CABAL} v2-build $WITHCOMPILER --disable-tests --disable-benchmarks --constraint='these <1' all | color_cabal_output
177− # Constraint set don't use split these/semialign
167+ # Constraint set old-witherable
178− - ${CABAL} v2-build $WITHCOMPILER --disable-tests --disable-benchmarks --constraint='reflex -split-these' all | color_cabal_output
168+ - ${CABAL} v2-build $WITHCOMPILER --disable-tests --disable-benchmarks --constraint='witherable <0.3.2' all | color_cabal_output
179
169
180# REGENDATA ["--config=cabal.haskell-ci","cabal.project"]
170# REGENDATA ["--config=cabal.haskell-ci","cabal.project"]
181# EOF
171# EOF
182−
cabal.haskell-ci+10−2
@@ -1,8 +1,16 @@
1−distribution: xenial
1+distribution: xenial
2+benchmarks: False
3+unconstrained: False
4+installed: -all
2
5
3-- https://github.com/haskell/cabal/issues/6106
6-- https://github.com/haskell/cabal/issues/6106
4install-dependencies: False
7install-dependencies: False
5−benchmarks: False
6
8
7constraint-set no-th
9constraint-set no-th
8 constraints: reflex -use-template-haskell
10 constraints: reflex -use-template-haskell
11+
12+constraint-set old-these
13+ constraints: these <1
14+
15+constraint-set old-witherable
16+ constraints: witherable <0.3.2
cabal.project.freezenew file+1
@@ -0,0 +1 @@
1+constraints: any.text < 1.2.4.0
default.nix+1−1
@@ -6,7 +6,7 @@
6, template-haskell , these, time, transformers
6, template-haskell , these, time, transformers
7, transformers-compat, unbounded-delays, prim-uniq
7, transformers-compat, unbounded-delays, prim-uniq
8, data-default, filepath, directory, filemanip, ghcjs-base
8, data-default, filepath, directory, filemanip, ghcjs-base
9−, monoidal-containers, witherable
9+, monoidal-containers, witherable, profunctors
10, semialign ? null, splitThese ? (semialign != null)
10, semialign ? null, splitThese ? (semialign != null)
11, useTemplateHaskell ? true
11, useTemplateHaskell ? true
12}:
12}:
reflex.cabal+1−1
@@ -79,7 +79,7 @@ library
79 time >= 1.4 && < 1.9,
79 time >= 1.4 && < 1.9,
80 transformers >= 0.5.6.0 && < 0.6,
80 transformers >= 0.5.6.0 && < 0.6,
81 unbounded-delays >= 0.1.0.0 && < 0.2,
81 unbounded-delays >= 0.1.0.0 && < 0.2,
82− witherable >= 0.2 && < 0.3
82+ witherable >= 0.2 && < 0.4
83
83
84 if flag(split-these)
84 if flag(split-these)
85 build-depends: these >= 1 && <1.1,
85 build-depends: these >= 1 && <1.1,
src/Data/AppendMap.hs+2
@@ -46,8 +46,10 @@ _unAppendMap = getMonoidalMap
46pattern AppendMap :: Map k v -> MonoidalMap k v
46pattern AppendMap :: Map k v -> MonoidalMap k v
47pattern AppendMap m = MonoidalMap m
47pattern AppendMap m = MonoidalMap m
48
48
49+#if !MIN_VERSION_witherable(0,3,2)
49instance W.Filterable (MonoidalMap k) where
50instance W.Filterable (MonoidalMap k) where
50 mapMaybe = mapMaybe
51 mapMaybe = mapMaybe
52+#endif
51
53
52-- | Deletes a key, returning 'Nothing' if the result is empty.
54-- | Deletes a key, returning 'Nothing' if the result is empty.
53nonEmptyDelete :: Ord k => k -> MonoidalMap k a -> Maybe (MonoidalMap k a)
55nonEmptyDelete :: Ord k => k -> MonoidalMap k a -> Maybe (MonoidalMap k a)
test/Reflex/Test/CrossImpl.hs+5
@@ -218,6 +218,11 @@ testCases =
218 bb <- hold b $ pushAlways (const $ hold "asdf" eo) eo
218 bb <- hold b $ pushAlways (const $ hold "asdf" eo) eo
219 let b' = pull $ sample =<< sample bb
219 let b' = pull $ sample =<< sample bb
220 return (b', e)
220 return (b', e)
221+ , (,) "foldDynWhileFiring" $ TestCase (Map.singleton 0 "zxc", Map.fromList [(1, "qwer"), (2, "lkj")]) $ \(_, e) -> do
222+ d <- foldDyn (:) [] $
223+ pushAlways (\a -> foldDyn (:) [a] e) e
224+ let b = current (join (fmap distributeListOverDynPure d))
225+ return (b, e)
221 , (,) "joinDyn" $ TestCase (Map.singleton 0 (0 :: Int), Map.fromList [(1, "qwer"), (2, "lkj")]) $ \(b, e) -> do
226 , (,) "joinDyn" $ TestCase (Map.singleton 0 (0 :: Int), Map.fromList [(1, "qwer"), (2, "lkj")]) $ \(b, e) -> do
222 bb <- hold "b" e
227 bb <- hold "b" e
223 bd <- hold never . fmap (const e) =<< headE e
228 bd <- hold never . fmap (const e) =<< headE e