Commit d6b170f1 authored by Ryan Scott's avatar Ryan Scott

Update cassva/hpack/yesod-core patches, drop attoparsec/shelly patches

* Update the patches for `cassava`, `hpack`, and `yesod-core` to the
  latest Hackage releases.
* Drop the `attoparsec` and `shelly` patches, as the latest Hackage
  releases support GHC 8.8.1 and HEAD.
parent 1530228b
Pipeline #9829 failed with stages
in 84 minutes and 38 seconds
name: attoparsec
version: 0.13.2.2
x-revision: 3
license: BSD3
license-file: LICENSE
category: Text, Parsing
author: Bryan O'Sullivan <bos@serpentine.com>
maintainer: Bryan O'Sullivan <bos@serpentine.com>, Ben Gamari <ben@smart-cactus.org>
stability: experimental
tested-with: GHC == 7.0.4, GHC == 7.2.2, GHC == 7.4.2, GHC ==7.6.3, GHC ==7.8.4, GHC ==7.10.3, GHC ==8.0.2, GHC ==8.2.2
synopsis: Fast combinator parsing for bytestrings and text
cabal-version: >= 1.8
homepage: https://github.com/bos/attoparsec
bug-reports: https://github.com/bos/attoparsec/issues
build-type: Simple
description:
A fast parser combinator library, aimed particularly at dealing
efficiently with network protocols and complicated text/binary
file formats.
extra-source-files:
README.markdown
benchmarks/*.cabal
benchmarks/*.hs
benchmarks/*.txt
benchmarks/json-data/*.json
benchmarks/Makefile
benchmarks/med.txt.bz2
changelog.md
examples/*.c
examples/*.hs
examples/Makefile
tests/*.hs
tests/QC/*.hs
tests/QC/IPv6/*.hs
Flag developer
Description: Whether to build the library in development mode
Default: False
Manual: True
library
build-depends: array,
base >= 4.2 && < 5,
bytestring,
containers,
deepseq,
scientific >= 0.3.1 && < 0.4,
transformers >= 0.2 && (< 0.4 || >= 0.4.1.0) && < 0.6,
text >= 1.1.1.3
if impl(ghc < 7.4)
build-depends:
bytestring < 0.10.4.0
if !impl(ghc >= 8.0)
-- Data.Semigroup && Control.Monad.Fail are available in base-4.9+
build-depends: fail == 4.9.*,
semigroups >=0.16.1 && <0.20
exposed-modules: Data.Attoparsec
Data.Attoparsec.ByteString
Data.Attoparsec.ByteString.Char8
Data.Attoparsec.ByteString.Lazy
Data.Attoparsec.Char8
Data.Attoparsec.Combinator
Data.Attoparsec.Internal
Data.Attoparsec.Internal.Types
Data.Attoparsec.Lazy
Data.Attoparsec.Number
Data.Attoparsec.Text
Data.Attoparsec.Text.Lazy
Data.Attoparsec.Types
Data.Attoparsec.Zepto
other-modules: Data.Attoparsec.ByteString.Buffer
Data.Attoparsec.ByteString.FastSet
Data.Attoparsec.ByteString.Internal
Data.Attoparsec.Internal.Fhthagn
Data.Attoparsec.Text.Buffer
Data.Attoparsec.Text.FastSet
Data.Attoparsec.Text.Internal
ghc-options: -O2 -Wall
if flag(developer)
ghc-prof-options: -auto-all
ghc-options: -Werror
test-suite tests
type: exitcode-stdio-1.0
hs-source-dirs: tests .
main-is: QC.hs
other-modules: QC.Buffer
QC.ByteString
QC.Combinator
QC.Common
QC.IPv6.Internal
QC.IPv6.Types
QC.Rechunked
QC.Simple
QC.Text
QC.Text.FastSet
QC.Text.Regressions
other-modules: Data.Attoparsec.ByteString
Data.Attoparsec.ByteString.Buffer
Data.Attoparsec.ByteString.Char8
Data.Attoparsec.ByteString.FastSet
Data.Attoparsec.ByteString.Internal
Data.Attoparsec.ByteString.Lazy
Data.Attoparsec.Combinator
Data.Attoparsec.Internal
Data.Attoparsec.Internal.Fhthagn
Data.Attoparsec.Internal.Types
Data.Attoparsec.Number
Data.Attoparsec.Text
Data.Attoparsec.Text.Buffer
Data.Attoparsec.Text.FastSet
Data.Attoparsec.Text.Internal
Data.Attoparsec.Text.Lazy
Data.Attoparsec.Zepto
ghc-options:
-Wall -threaded -rtsopts
if flag(developer)
ghc-options: -Werror
build-depends:
array,
base >= 4 && < 5,
bytestring,
deepseq >= 1.1,
QuickCheck >= 2.7 && < 2.10,
quickcheck-unicode,
scientific,
tasty >= 0.11,
tasty-quickcheck >= 0.8,
text,
transformers >= 0.2 && (< 0.4 || >= 0.4.1.0) && < 0.6,
vector
if !impl(ghc >= 8.0)
-- Data.Semigroup && Control.Monad.Fail are available in base-4.9+
build-depends: fail == 4.9.*,
semigroups >=0.16.1 && <0.20
benchmark benchmarks
type: exitcode-stdio-1.0
hs-source-dirs: benchmarks benchmarks/warp-3.0.1.1 .
ghc-options: -O2 -Wall -rtsopts
main-is: Benchmarks.hs
other-modules:
Common
HeadersByteString
HeadersByteString.Atto
HeadersText
Links
Network.Wai.Handler.Warp.ReadInt
Network.Wai.Handler.Warp.RequestHeader
Numbers
Sets
TextFastSet
Warp
ghc-options: -O2 -Wall
if flag(developer)
ghc-options: -Werror
build-depends:
array,
base == 4.*,
bytestring >= 0.10.4.0,
case-insensitive,
containers,
criterion >= 1.0,
deepseq >= 1.1,
directory,
filepath,
ghc-prim,
http-types,
parsec >= 3.1.2,
scientific,
text >= 1.1.1.0,
transformers >= 0.2 && (< 0.4 || >= 0.4.1.0) && < 0.6,
unordered-containers,
vector
if !impl(ghc >= 8.0)
-- Data.Semigroup && Control.Monad.Fail are available in base-4.9+
build-depends: fail == 4.9.*,
semigroups >=0.16.1 && <0.19
source-repository head
type: git
location: https://github.com/bos/attoparsec
commit de0cf2890b9602021d6e18a2523ccdf39816d599
Author: Ryan Scott <ryan.gl.scott@gmail.com>
Date: Fri Mar 15 18:18:54 2019 -0400
Adapt to base-4.13.0.0
diff --git a/Data/Attoparsec/Internal/Types.hs b/Data/Attoparsec/Internal/Types.hs
index 7560f22..b848345 100644
--- a/Data/Attoparsec/Internal/Types.hs
+++ b/Data/Attoparsec/Internal/Types.hs
@@ -1,4 +1,4 @@
-{-# LANGUAGE BangPatterns, GeneralizedNewtypeDeriving, OverloadedStrings,
+{-# LANGUAGE CPP, BangPatterns, GeneralizedNewtypeDeriving, OverloadedStrings,
Rank2Types, RecordWildCards, TypeFamilies #-}
-- |
-- Module : Data.Attoparsec.Internal.Types
@@ -136,8 +136,10 @@ instance Mon.Monoid More where
mempty = Incomplete
instance Monad (Parser i) where
+#if !(MIN_VERSION_base(4,13,0))
fail = Fail.fail
{-# INLINE fail #-}
+#endif
return = App.pure
{-# INLINE return #-}
diff --git a/Data/Attoparsec/Zepto.hs b/Data/Attoparsec/Zepto.hs
index 5af5bb6..da2c244 100644
--- a/Data/Attoparsec/Zepto.hs
+++ b/Data/Attoparsec/Zepto.hs
@@ -92,8 +92,10 @@ instance Monad m => Monad (ZeptoT m) where
Fail err -> return (Fail err)
{-# INLINE (>>=) #-}
+#if !(MIN_VERSION_base(4,13,0))
fail = Fail.fail
{-# INLINE fail #-}
+#endif
instance Monad m => Fail.MonadFail (ZeptoT m) where
fail msg = Parser $ \_ -> return (Fail msg)
diff -ru cassava-0.5.1.0.orig/Data/Csv/Conversion.hs cassava-0.5.1.0/Data/Csv/Conversion.hs
--- cassava-0.5.1.0.orig/Data/Csv/Conversion.hs 2017-08-12 12:05:04.000000000 -0400
+++ cassava-0.5.1.0/Data/Csv/Conversion.hs 2019-03-15 19:00:40.945760943 -0400
@@ -1188,8 +1188,10 @@
{-# INLINE (>>) #-}
return = pure
{-# INLINE return #-}
+#if !(MIN_VERSION_base(4,13,0))
fail = Fail.fail
{-# INLINE fail #-}
+#endif
-- | @since 0.5.0.0
instance Fail.MonadFail Parser where
cabal-version: 1.12
Name: cassava
Version: 0.5.1.0
x-revision: 2
Version: 0.5.2.0
Synopsis: A CSV parsing and encoding library
Description: {
......@@ -43,7 +42,7 @@ Build-type: Simple
Extra-source-files: examples/*.hs,
CHANGES.md,
README.md
Tested-with: GHC ==8.2.1, GHC ==8.0.2, GHC ==8.0.1, GHC ==7.10.3, GHC ==7.8.4, GHC ==7.6.3, GHC ==7.4.2
Tested-with: GHC==8.8.1, GHC==8.6.5, GHC==8.4.4, GHC ==8.2.2, GHC ==8.0.2, GHC ==7.10.3, GHC ==7.8.4, GHC ==7.6.3, GHC ==7.4.2
----------------------------------------------------------------------------
......@@ -81,6 +80,8 @@ Library
DataKinds
PolyKinds
hs-source-dirs: src
Exposed-modules:
Data.Csv
Data.Csv.Builder
......@@ -98,13 +99,14 @@ Library
Build-depends:
array >= 0.4 && < 0.6,
attoparsec >= 0.11.3.0 && < 0.14,
base >= 4.5 && < 5,
base >= 4.5 && < 4.14,
bytestring >= 0.9.2 && < 0.11,
containers >= 0.4.2 && < 0.7,
deepseq >= 1.1 && < 1.5,
hashable < 1.4,
scientific >= 0.3.4.7 && < 0.4,
text < 1.3,
transformers >= 0.2 && < 0.6,
unordered-containers < 0.3,
vector >= 0.8 && < 0.13,
Only >= 0.1 && < 0.1.1
......@@ -126,7 +128,11 @@ Library
-- https://ghc.haskell.org/trac/ghc/wiki/Migration/8.0#Recommendationsforforward-compatibility
if impl(ghc >= 8.0)
ghc-options: -Wcompat -Wnoncanonical-monad-instances -Wnoncanonical-monadfail-instances
ghc-options: -Wcompat -Wnoncanonical-monad-instances
if impl(ghc >= 8.8)
ghc-options: -Wno-star-is-type
else
ghc-options: -Wnoncanonical-monadfail-instances
else
-- provide/emulate `Control.Monad.Fail` and `Data.Semigroups` API for pre-GHC8
build-depends: fail == 4.9.*, semigroups >= 0.18.2 && <0.20
......@@ -155,7 +161,7 @@ Test-suite unit-tests
, vector
-- extra dependencies not already used by lib:cassava
build-depends: HUnit < 1.7
, QuickCheck == 2.10.*
, QuickCheck == 2.13.*
, quickcheck-instances >= 0.3.12 && < 0.4
, test-framework == 0.8.*
, test-framework-hunit == 0.3.*
......
commit 08fd62bccfb0aa1f2248678c378453e065239259
commit a9ab5f51d2a59e2d0b738739670d811ad6436bdd
Author: Ryan Scott <ryan.gl.scott@gmail.com>
Date: Tue Mar 26 20:03:54 2019 -0400
Date: Sun Sep 1 10:08:32 2019 -0400
Adapt to GHC 8.8
......@@ -37,27 +37,6 @@ index 5710b49..aba76b9 100644
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE CPP #-}
diff --git a/src/Hpack/License.hs b/src/Hpack/License.hs
index d3a69cb..4786a3b 100644
--- a/src/Hpack/License.hs
+++ b/src/Hpack/License.hs
@@ -1,3 +1,4 @@
+{-# LANGUAGE CPP #-}
{-# LANGUAGE DeriveFunctor #-}
{-# LANGUAGE ViewPatterns #-}
{-# LANGUAGE LambdaCase #-}
@@ -9,7 +10,11 @@ import Distribution.Pretty (prettyShow)
import Distribution.Version (mkVersion)
import qualified Distribution.License as Cabal
import qualified Distribution.SPDX.License as SPDX
+#if MIN_VERSION_Cabal(2,5,0)
+import Distribution.Parsec (eitherParsec)
+#else
import Distribution.Parsec.Class (eitherParsec)
+#endif
import qualified Data.License.Infer as Infer
diff --git a/src/Hpack/Syntax/BuildTools.hs b/src/Hpack/Syntax/BuildTools.hs
index a27819e..df6d917 100644
--- a/src/Hpack/Syntax/BuildTools.hs
......@@ -119,15 +98,10 @@ index 14c09f7..fdd6671 100644
where
fromCabal :: D.Dependency -> (String, DependencyVersion)
diff --git a/src/Hpack/Syntax/DependencyVersion.hs b/src/Hpack/Syntax/DependencyVersion.hs
index cb8abcf..7eef78c 100644
index 381c3f8..d4e5bc2 100644
--- a/src/Hpack/Syntax/DependencyVersion.hs
+++ b/src/Hpack/Syntax/DependencyVersion.hs
@@ -1,3 +1,4 @@
+{-# LANGUAGE CPP #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE LambdaCase #-}
module Hpack.Syntax.DependencyVersion (
@@ -24,6 +25,7 @@ module Hpack.Syntax.DependencyVersion (
@@ -25,6 +25,7 @@ module Hpack.Syntax.DependencyVersion (
) where
import Control.Applicative
......@@ -135,20 +109,7 @@ index cb8abcf..7eef78c 100644
import Data.Maybe
import Data.Scientific
import Data.Text (Text)
@@ -34,7 +36,12 @@ import Text.PrettyPrint (renderStyle, Style(..), Mode(..))
import Distribution.Version (VersionRangeF(..))
import qualified Distribution.Text as D
import qualified Distribution.Version as D
+#if MIN_VERSION_Cabal(2,5,0)
+import qualified Distribution.Parsec as D
+import qualified Distribution.Pretty as D
+#else
import qualified Distribution.Parsec.Class as D
+#endif
import Data.Aeson.Config.FromValue
@@ -133,13 +140,13 @@ scientificToVersion n = version
@@ -140,13 +141,13 @@ scientificToVersion n = version
| otherwise = 0
e = base10Exponent n
......@@ -165,39 +126,3 @@ index cb8abcf..7eef78c 100644
cabalParse subject s = case D.eitherParsec s of
Right d -> return d
Left _ ->fail $ unwords ["invalid", subject, show s]
@@ -147,7 +154,13 @@ cabalParse subject s = case D.eitherParsec s of
versionConstraintFromCabal :: D.VersionRange -> VersionConstraint
versionConstraintFromCabal range
| D.isAnyVersion range = AnyVersion
- | otherwise = VersionRange . renderStyle style . D.disp $ toPreCabal2VersionRange range
+ | otherwise = VersionRange . renderStyle style
+#if MIN_VERSION_Cabal(2,5,0)
+ . D.pretty
+#else
+ . D.disp
+#endif
+ $ toPreCabal2VersionRange range
where
style = Style OneLineMode 0 0
diff --git a/test/Hpack/LicenseSpec.hs b/test/Hpack/LicenseSpec.hs
index ce6cb1a..ffb7d25 100644
--- a/test/Hpack/LicenseSpec.hs
+++ b/test/Hpack/LicenseSpec.hs
@@ -1,3 +1,4 @@
+{-# LANGUAGE CPP #-}
{-# LANGUAGE QuasiQuotes #-}
module Hpack.LicenseSpec (spec) where
@@ -6,7 +7,11 @@ import Data.Maybe
import Data.String.Interpolate
import Distribution.Pretty (prettyShow)
+#if MIN_VERSION_Cabal(2,5,0)
+import Distribution.Parsec (simpleParsec)
+#else
import Distribution.Parsec.Class (simpleParsec)
+#endif
import qualified Distribution.License as Cabal
import Hpack.License
Name: shelly
Version: 1.8.1
x-revision: 1
Synopsis: shell-like (systems) programming in Haskell
Description: Shelly provides convenient systems programming in Haskell,
similar in spirit to POSIX shells. Shelly:
.
* is aimed at convenience and getting things done rather than
being a demonstration of elegance.
.
* has detailed and useful error messages
.
* maintains its own environment, making it thread-safe.
.
* is modern, using Text and system-filepath/system-fileio
.
Shelly is originally forked from the Shellish package.
.
See the shelly-extra package for additional functionality.
.
An overview is available in the README: <https://github.com/yesodweb/Shelly.hs/blob/master/README.md>
Homepage: https://github.com/yesodweb/Shelly.hs
License: BSD3
License-file: LICENSE
Author: Greg Weber, Petr Rockai
Maintainer: Greg Weber <greg@gregweber.info>
Category: Development
Build-type: Simple
Cabal-version: >=1.8
-- for the sdist of the test suite
extra-source-files: test/src/*.hs
test/examples/*.sh
test/examples/*.hs
test/data/zshrc
test/data/nonascii.txt
test/data/symlinked_dir/hoge_file
test/testall
README.md
ChangeLog.md
Library
Exposed-modules: Shelly, Shelly.Lifted, Shelly.Pipe, Shelly.Unix
other-modules: Shelly.Base, Shelly.Find, Shelly.Directory
hs-source-dirs: src
other-extensions: InstanceSigs
Build-depends:
containers >= 0.4.2.0,
time >= 1.3 && < 1.9,
directory >= 1.3.0.0 && < 1.4.0.0,
mtl >= 2,
process >= 1.0,
unix-compat < 0.6,
unix,
system-filepath >= 0.4.7 && < 0.5,
system-fileio < 0.4,
monad-control >= 0.3.2 && < 1.1,
lifted-base,
lifted-async,
exceptions >= 0.6,
enclosed-exceptions,
text, bytestring, async, transformers, transformers-base
if impl(ghc >= 7.6.1)
build-depends:
base >= 4.6 && < 5
else
build-depends:
base >= 4 && < 5
ghc-options: -Wall
if impl(ghc >= 7.6.1)
CPP-Options: -DNO_PRELUDE_CATCH
extensions:
CPP
source-repository head
type: git
location: https://github.com/yesodweb/Shelly.hs
Flag lifted
Description: run the tests against Shelly.Lifted
Default: False
Test-Suite shelly-testsuite
type: exitcode-stdio-1.0
hs-source-dirs: src test/src
main-is: TestMain.hs
other-modules:
CopySpec
EnvSpec
FailureSpec
FindSpec
Help
LiftedSpec
MoveSpec
ReadFileSpec
RmSpec
RunSpec
SshSpec
Shelly
Shelly.Base
Shelly.Find
Shelly.Lifted
TestInit
WhichSpec
WriteSpec
ghc-options: -O2 -Wall -fwarn-tabs -funbox-strict-fields -threaded
-fno-warn-unused-do-bind -fno-warn-type-defaults
extensions: OverloadedStrings, ExtendedDefaultRules
if flag(lifted)
cpp-options: -DLIFTED
build-depends:
base >= 4.6,
text >= 0.11,
async,
bytestring >= 0.10,
containers >= 0.5.0.0,
directory >= 1.3.0.0 && < 1.4.0.0,
process >= 1.1.0,
unix-compat < 0.6,
unix,
system-filepath >= 0.4.7 && < 0.5,
system-fileio < 0.4,
time >= 1.3 && < 1.9,
mtl >= 2,
HUnit >= 1.2,
hspec >= 2.0,
hspec-contrib,
transformers,
transformers-base,
filepath,
monad-control,
lifted-base,
lifted-async,
enclosed-exceptions,
exceptions
extensions:
CPP
Flag build-examples
Description: build some example programs
Default: False
Manual: True
-- demonstarated that command output in Shellish was not shown until after the command finished
-- not necessary anymore
Executable drain
hs-source-dirs: test/examples
main-is: drain.hs
if flag(build-examples)
buildable: True
build-depends: base >= 4.6
, shelly
, text
extensions:
CPP
else
buildable: False
Executable run-handles
hs-source-dirs: test/examples
main-is: run-handles.hs
if flag(build-examples)
buildable: True
build-depends: base >= 4.6
, shelly
, text
extensions:
CPP
else
buildable: False
Executable Color
hs-source-dirs: test/examples
main-is: color.hs
if flag(build-examples)
buildable: True
build-depends: base >= 4.6
, process
, shelly
, text
else
buildable: False
diff -ru shelly-1.8.1.orig/src/Shelly/Base.hs shelly-1.8.1/src/Shelly/Base.hs
--- shelly-1.8.1.orig/src/Shelly/Base.hs 2018-03-17 15:19:41.000000000 -0400
+++ shelly-1.8.1/src/Shelly/Base.hs 2019-03-15 18:08:54.388824423 -0400
@@ -45,6 +45,7 @@
liftM
)
import Control.Monad.Base
+import qualified Control.Monad.Fail as Fail
import Control.Monad.Trans.Control
import Control.Applicative (Applicative, (<$>))
import Filesystem (isDirectory, listDirectory)
@@ -71,7 +72,7 @@
newtype Sh a = Sh {
unSh :: ReaderT (IORef State) IO a
- } deriving (Applicative, Monad, MonadIO, MonadReader (IORef State), Functor, Catch.MonadMask)
+ } deriving (Applicative, Monad, MonadIO, MonadReader (IORef State), Functor, Catch.MonadMask, Fail.MonadFail)
instance MonadBase IO Sh where
liftBase = Sh . ReaderT . const
diff -ru yesod-core-1.6.15.orig/src/Yesod/Routes/TH/RenderRoute.hs yesod-core-1.6.15/src/Yesod/Routes/TH/RenderRoute.hs
--- yesod-core-1.6.15.orig/src/Yesod/Routes/TH/RenderRoute.hs 2019-07-18 07:55:12.000000000 -0400
+++ yesod-core-1.6.15/src/Yesod/Routes/TH/RenderRoute.hs 2019-08-28 07:23:41.653975261 -0400
diff -ru yesod-core-1.6.16.orig/src/Yesod/Routes/TH/RenderRoute.hs yesod-core-1.6.16/src/Yesod/Routes/TH/RenderRoute.hs
--- yesod-core-1.6.16.orig/src/Yesod/Routes/TH/RenderRoute.hs 2019-07-18 07:55:12.000000000 -0400
+++ yesod-core-1.6.16/src/Yesod/Routes/TH/RenderRoute.hs 2019-09-01 09:50:29.375154816 -0400
@@ -84,7 +84,13 @@
let cons y ys = InfixE (Just y) colon (Just ys)
let pieces' = foldr cons (VarE a) piecesSingle
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment