on master help sign in
Bump lower bound of http-types >= 0.12

- WIP: pending http-api-data release - TODO: remove MIN_VERSION_http_types - There have been 3 major releases of http-types: - 0.10 change name of variable - 0.11 lowercase escaped URIs - 0.12 uppercase escaped URIs - It's easier for us to support only latest, migration from 0.9/0.10 to 0.12 is trivial for the downstream. 0.11 may cause semantic (non-type-error) breakage somewhere. Also allow lens-4.16, remove MIN_VERSION_http_types conditionals, and update `stack.yaml`

commitc55b778d8ea481dd004fca20b6c9d16a6753754b authorOleg Grenrus <oleg.grenrus@iki.fi> dateSun 28 Jan 2018, 18:26 (9 years ago) parentf1baef6
15 files changed+20−27
.travis.yml+3−3 cabal.project+1−1 doc/cookbook/basic-auth/basic-auth.cabal+1−1 doc/cookbook/db-postgres-pool/db-postgres-pool.cabal+1−1 doc/cookbook/db-sqlite-simple/db-sqlite-simple.cabal+1−1 doc/cookbook/jwt-and-basic-auth/jwt-and-basic-auth.cabal+1−1 servant-client-core/servant-client-core.cabal+1−1 servant-client-ghcjs/servant-client-ghcjs.cabal+1−1 servant-client/servant-client.cabal+1−1 servant-docs/servant-docs.cabal+2−2 servant-foreign/servant-foreign.cabal+2−2 servant-server/servant-server.cabal+1−1 servant-server/test/Servant/ServerSpec.hs−10 servant/servant.cabal+1−1 stack.yaml+3
.travis.yml+3−3
@@ -71,7 +71,7 @@ install:
7171 - grep -Ev -- '^\s*--' ${HOME}/.cabal/config | grep -Ev '^\s*$'
7272 - "printf 'packages: \"servant\" \"servant-client\" \"servant-client-core\" \"servant-docs\" \"servant-foreign\" \"servant-server\" \"doc/tutorial\" \"doc/cookbook/db-postgres-pool\" \"doc/cookbook/jwt-and-basic-auth\" \"doc/cookbook/db-sqlite-simple\" \"doc/cookbook/basic-auth\" \"doc/cookbook/https\" \"doc/cookbook/structuring-apis\" \"doc/cookbook/using-custom-monad\" \"doc/cookbook/file-upload\"\\n' > cabal.project"
7373 - "echo 'constraints: foundation >=0.0.14,memory <0.14.12 || >0.14.12' >> cabal.project"
74− - "echo 'allow-newer: servant-js:servant-foreign' >> cabal.project"
74+ - "echo 'allow-newer: servant-js:servant-foreign, servant-auth-server:http-types, servant-multipart:lens' >> cabal.project"
7575 - cat cabal.project
7676 - if [ -f "servant/configure.ac" ]; then
7777 (cd "servant" && autoreconf -i);
@@ -149,14 +149,14 @@ script:
149149 - find . -maxdepth 1 -name '*.tar.gz' -exec tar -xvf '{}' \;
150150 - "printf 'packages: servant-*/*.cabal servant-client-*/*.cabal servant-client-core-*/*.cabal servant-docs-*/*.cabal servant-foreign-*/*.cabal servant-server-*/*.cabal tutorial-*/*.cabal cookbook-db-postgres-pool-*/*.cabal cookbook-jwt-and-basic-auth-*/*.cabal cookbook-db-sqlite-simple-*/*.cabal cookbook-basic-auth-*/*.cabal cookbook-https-*/*.cabal cookbook-structuring-apis-*/*.cabal cookbook-using-custom-monad-*/*.cabal cookbook-file-upload-*/*.cabal\\n' > cabal.project"
151151 - "echo 'constraints: foundation >=0.0.14,memory <0.14.12 || >0.14.12' >> cabal.project"
152− - "echo 'allow-newer: servant-js:servant-foreign' >> cabal.project"
152+ - "echo 'allow-newer: servant-js:servant-foreign, servant-auth-server:http-types, servant-multipart:lens' >> cabal.project"
153153 - cat cabal.project
154154 - echo -en 'travis_fold:end:unpack\\r'
155155
156156
157157 - echo Building with tests and benchmarks... && echo -en 'travis_fold:start:build-everything\\r'
158158 # build & run tests, build benchmarks
159− - cabal new-build -w ${HC} ${TEST} ${BENCH} all --max-backjumps=20000
159+ - cabal new-build -w ${HC} ${TEST} ${BENCH} all
160160 - echo -en 'travis_fold:end:build-everything\\r'
161161 - if [ "x$TEST" = "x--enable-tests" ]; then cabal new-test -w ${HC} ${TEST} ${BENCH} all; fi
162162
cabal.project+1−1
@@ -7,7 +7,7 @@ packages: servant/
77 doc/tutorial/
88 doc/cookbook/*/*.cabal
99
10−allow-newer: servant-js:servant-foreign
10+allow-newer: servant-js:servant-foreign, servant-auth-server:http-types, servant-multipart:lens
1111
1212constraints:
1313 -- see https://github.com/haskell-infra/hackage-trustees/issues/119
doc/cookbook/basic-auth/basic-auth.cabal+1−1
@@ -21,7 +21,7 @@ executable cookbook-basic-auth
2121 , servant-server
2222 , warp >= 3.2
2323 , wai >= 3.2
24− , http-types >= 0.10
24+ , http-types >= 0.12
2525 , markdown-unlit >= 0.4
2626 , http-client >= 0.5
2727 default-language: Haskell2010
doc/cookbook/db-postgres-pool/db-postgres-pool.cabal+1−1
@@ -21,7 +21,7 @@ executable cookbook-db-postgres-pool
2121 , servant-server
2222 , warp >= 3.2
2323 , wai >= 3.2
24− , http-types >= 0.10
24+ , http-types >= 0.12
2525 , markdown-unlit >= 0.4
2626 , http-client >= 0.5
2727 , postgresql-simple >= 0.5
doc/cookbook/db-sqlite-simple/db-sqlite-simple.cabal+1−1
@@ -20,7 +20,7 @@ executable cookbook-db-sqlite-simple
2020 , servant-server
2121 , warp >= 3.2
2222 , wai >= 3.2
23− , http-types >= 0.10
23+ , http-types >= 0.12
2424 , markdown-unlit >= 0.4
2525 , http-client >= 0.5
2626 , sqlite-simple >= 0.4
doc/cookbook/jwt-and-basic-auth/jwt-and-basic-auth.cabal+1−1
@@ -29,7 +29,7 @@ executable cookbook-jwt-and-basic-auth
2929 , servant-auth-server >= 0.3.1.0
3030 , warp >= 3.2
3131 , wai >= 3.2
32− , http-types >= 0.10
32+ , http-types >= 0.12
3333 , markdown-unlit >= 0.4
3434 , http-client >= 0.5
3535 , bytestring >= 0.10.4
servant-client-core/servant-client-core.cabal+1−1
@@ -68,7 +68,7 @@ library
6868 , generics-sop >= 0.3.1.0 && < 0.4
6969 , http-api-data >= 0.3.7.1 && < 0.4
7070 , http-media >= 0.7.1.1 && < 0.8
71− , http-types >= 0.9.1 && < 0.12
71+ , http-types >= 0.12 && < 0.13
7272 , network-uri >= 2.6.1.0 && < 2.7
7373 , safe >= 0.3.15 && < 0.4
7474
servant-client-ghcjs/servant-client-ghcjs.cabal+1−1
@@ -39,7 +39,7 @@ library
3939 , ghcjs-base >= 0.2.0.0 && < 0.3.0.0
4040 , ghcjs-prim >= 0.1.0.0 && < 0.2.0.0
4141 , http-media >= 0.6.2 && < 0.8
42− , http-types >= 0.8.6 && < 0.12
42+ , http-types >= 0.12 && < 0.13
4343 , monad-control >= 1.0.0.4 && < 1.1
4444 , mtl >= 2.1 && < 2.3
4545 , semigroupoids >= 4.3 && < 5.3
servant-client/servant-client.cabal+1−1
@@ -62,7 +62,7 @@ library
6262 , http-client >= 0.5.7.1 && < 0.6
6363 , http-client-tls >= 0.3.5.1 && < 0.4
6464 , http-media >= 0.7.1.1 && < 0.8
65− , http-types >= 0.9.1 && < 0.12
65+ , http-types >= 0.12 && < 0.13
6666 , exceptions >= 0.8.3 && < 0.9
6767 , monad-control >= 1.0.0.4 && < 1.1
6868 , semigroupoids >= 5.2.1 && < 5.3
servant-docs/servant-docs.cabal+2−2
@@ -63,8 +63,8 @@ library
6363 , control-monad-omega >= 0.3.1 && < 0.4
6464 , hashable >= 1.2.6.1 && < 1.3
6565 , http-media >= 0.7.1.1 && < 0.8
66− , http-types >= 0.9.1 && < 0.12
67− , lens >= 4.15.4 && < 4.16
66+ , http-types >= 0.12 && < 0.13
67+ , lens >= 4.15.4 && < 4.17
6868 , string-conversions >= 0.4.0.1 && < 0.5
6969 , unordered-containers >= 0.2.8.0 && < 0.3
7070
servant-foreign/servant-foreign.cabal+2−2
@@ -53,8 +53,8 @@ library
5353 -- Here can be exceptions if we really need features from the newer versions.
5454 build-depends:
5555 base-compat >= 0.9.3 && <0.10
56− , lens >= 4.15.4 && <4.16
57− , http-types >= 0.9.1 && < 0.12
56+ , lens >= 4.15.4 && <4.17
57+ , http-types >= 0.12 && < 0.13
5858
5959 hs-source-dirs: src
6060 default-language: Haskell2010
servant-server/servant-server.cabal+1−1
@@ -82,7 +82,7 @@ library
8282 , exceptions >= 0.8.3 && < 0.9
8383 , http-api-data >= 0.3.7.1 && < 0.4
8484 , http-media >= 0.7.1.1 && < 0.8
85− , http-types >= 0.9.1 && < 0.12
85+ , http-types >= 0.12 && < 0.13
8686 , network-uri >= 2.6.1.0 && < 2.7
8787 , monad-control >= 1.0.0.4 && < 1.1
8888 , network >= 2.6.3.2 && < 2.7
servant-server/test/Servant/ServerSpec.hs−10
@@ -3,7 +3,6 @@
33{-# LANGUAGE DeriveGeneric #-}
44{-# LANGUAGE FlexibleContexts #-}
55{-# LANGUAGE FlexibleInstances #-}
6−{-# LANGUAGE FlexibleInstances #-}
76{-# LANGUAGE OverloadedStrings #-}
87{-# LANGUAGE PolyKinds #-}
98{-# LANGUAGE ScopedTypeVariables #-}
@@ -33,11 +32,7 @@ import Network.HTTP.Types (Status (..), hAccept, hContentType,
3332 methodDelete, methodGet,
3433 methodHead, methodPatch,
3534 methodPost, methodPut, ok200,
36−#if MIN_VERSION_http_types(0,10,0)
3735 imATeapot418,
38−#else
39− imATeaPot418,
40−#endif
4136 parseQuery)
4237import Network.Wai (Application, Request, requestHeaders, pathInfo,
4338 queryString, rawQueryString,
@@ -74,11 +69,6 @@ import Servant.Server.Experimental.Auth
7469import Servant.Server.Internal.Context
7570 (NamedContext(..))
7671
77−#if !MIN_VERSION_http_types(0,10,0)
78−imATeapot418 :: Status
79−imATeapot418 = imATeaPot418
80−#endif
81−
8272-- * comprehensive api test
8373
8474-- This declaration simply checks that all instances are in place.
servant/servant.cabal+1−1
@@ -87,7 +87,7 @@ library
8787 , case-insensitive >= 1.2.0.10 && < 1.3
8888 , http-api-data >= 0.3.7.1 && < 0.4
8989 , http-media >= 0.7.1.1 && < 0.8
90− , http-types >= 0.9.1 && < 0.12
90+ , http-types >= 0.12 && < 0.13
9191 , natural-transformation >= 0.4 && < 0.5
9292 , mmorph >= 1.1.0 && < 1.2
9393 , tagged >= 0.8.5 && < 0.9
stack.yaml+3
@@ -9,6 +9,9 @@ packages:
99- servant/
1010
1111extra-deps:
12+- cabal-doctest-1.0.6
13+- http-api-data-0.3.7.2
14+- http-types-0.12
1215- text-1.2.3.0
1316
1417# allow-newer: true # ignores all bounds, that's a sledgehammer