Skip to content

Commit

Permalink
Add instance Alternative (Either String) since transformers dropped it
Browse files Browse the repository at this point in the history
  • Loading branch information
thomasjm committed Jan 23, 2024
1 parent fa74fd2 commit 8cf2e34
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 6 deletions.
7 changes: 6 additions & 1 deletion lib/DockerEngine/Core.hs
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ import qualified Data.Text.Encoding as T
import qualified Data.Time as TI
import qualified Data.Time.Format.Internal as TI

Check failure on line 54 in lib/DockerEngine/Core.hs

View workflow job for this annotation

GitHub Actions / ubuntu-latest / ghc 8.6.5

Could not find module ‘Data.Time.Format.Internal’

Check failure on line 54 in lib/DockerEngine/Core.hs

View workflow job for this annotation

GitHub Actions / windows-latest / ghc 8.6.5

Could not find module ‘Data.Time.Format.Internal’

Check failure on line 54 in lib/DockerEngine/Core.hs

View workflow job for this annotation

GitHub Actions / macOS-latest / ghc 8.6.5

Could not find module ‘Data.Time.Format.Internal’
import qualified Data.Time.ISO8601 as TI
import qualified GHC.Base as P (Alternative)
import qualified GHC.Base as P (Alternative, empty)
import qualified Lens.Micro as L
import qualified Network.HTTP.Client.MultipartFormData as NH
import qualified Network.HTTP.Types as NH
Expand Down Expand Up @@ -447,6 +447,11 @@ instance P.Show DateTime where
instance MimeRender MimeMultipartFormData DateTime where
mimeRender _ = mimeRenderDefaultMultipartFormData

instance Alternative (P.Either String) where

Check failure on line 450 in lib/DockerEngine/Core.hs

View workflow job for this annotation

GitHub Actions / ubuntu-latest / ghc 8.8.4

• Overlapping instances for Alternative (P.Either String)

Check failure on line 450 in lib/DockerEngine/Core.hs

View workflow job for this annotation

GitHub Actions / ubuntu-latest / ghc 8.8.4

• Overlapping instances for Alternative (P.Either String)

Check failure on line 450 in lib/DockerEngine/Core.hs

View workflow job for this annotation

GitHub Actions / ubuntu-latest / ghc 8.10.7

• Overlapping instances for Alternative (P.Either String)

Check failure on line 450 in lib/DockerEngine/Core.hs

View workflow job for this annotation

GitHub Actions / ubuntu-latest / ghc 8.10.7

• Overlapping instances for Alternative (P.Either String)

Check failure on line 450 in lib/DockerEngine/Core.hs

View workflow job for this annotation

GitHub Actions / ubuntu-latest / ghc 9.2.7

• Overlapping instances for Alternative (P.Either String)

Check failure on line 450 in lib/DockerEngine/Core.hs

View workflow job for this annotation

GitHub Actions / ubuntu-latest / ghc 9.2.7

• Overlapping instances for Alternative (P.Either String)

Check failure on line 450 in lib/DockerEngine/Core.hs

View workflow job for this annotation

GitHub Actions / ubuntu-latest / ghc 9.0.2

• Overlapping instances for Alternative (P.Either String)

Check failure on line 450 in lib/DockerEngine/Core.hs

View workflow job for this annotation

GitHub Actions / ubuntu-latest / ghc 9.0.2

• Overlapping instances for Alternative (P.Either String)

Check failure on line 450 in lib/DockerEngine/Core.hs

View workflow job for this annotation

GitHub Actions / ubuntu-latest / ghc 9.4.5

• Overlapping instances for Alternative (P.Either String)

Check failure on line 450 in lib/DockerEngine/Core.hs

View workflow job for this annotation

GitHub Actions / ubuntu-latest / ghc 9.4.5

• Overlapping instances for Alternative (P.Either String)

Check failure on line 450 in lib/DockerEngine/Core.hs

View workflow job for this annotation

GitHub Actions / windows-latest / ghc 9.4.5

• Overlapping instances for Alternative (P.Either String)

Check failure on line 450 in lib/DockerEngine/Core.hs

View workflow job for this annotation

GitHub Actions / windows-latest / ghc 9.4.5

• Overlapping instances for Alternative (P.Either String)

Check warning on line 450 in lib/DockerEngine/Core.hs

View workflow job for this annotation

GitHub Actions / ubuntu-latest / ghc 9.6.2

Orphan instance: instance Alternative (P.Either String)

Check failure on line 450 in lib/DockerEngine/Core.hs

View workflow job for this annotation

GitHub Actions / windows-latest / ghc 8.10.7

• Overlapping instances for Alternative (P.Either String)

Check failure on line 450 in lib/DockerEngine/Core.hs

View workflow job for this annotation

GitHub Actions / windows-latest / ghc 8.10.7

• Overlapping instances for Alternative (P.Either String)

Check failure on line 450 in lib/DockerEngine/Core.hs

View workflow job for this annotation

GitHub Actions / windows-latest / ghc 9.0.2

• Overlapping instances for Alternative (P.Either String)

Check failure on line 450 in lib/DockerEngine/Core.hs

View workflow job for this annotation

GitHub Actions / windows-latest / ghc 9.0.2

• Overlapping instances for Alternative (P.Either String)

Check failure on line 450 in lib/DockerEngine/Core.hs

View workflow job for this annotation

GitHub Actions / macOS-latest / ghc 9.0.2

• Overlapping instances for Alternative (P.Either String)

Check failure on line 450 in lib/DockerEngine/Core.hs

View workflow job for this annotation

GitHub Actions / macOS-latest / ghc 9.0.2

• Overlapping instances for Alternative (P.Either String)

Check failure on line 450 in lib/DockerEngine/Core.hs

View workflow job for this annotation

GitHub Actions / windows-latest / ghc 9.2.7

• Overlapping instances for Alternative (P.Either String)

Check failure on line 450 in lib/DockerEngine/Core.hs

View workflow job for this annotation

GitHub Actions / windows-latest / ghc 9.2.7

• Overlapping instances for Alternative (P.Either String)

Check warning on line 450 in lib/DockerEngine/Core.hs

View workflow job for this annotation

GitHub Actions / windows-latest / ghc 9.6.2

Orphan instance: instance Alternative (P.Either String)

Check failure on line 450 in lib/DockerEngine/Core.hs

View workflow job for this annotation

GitHub Actions / windows-latest / ghc 8.8.4

• Overlapping instances for Alternative (P.Either String)

Check failure on line 450 in lib/DockerEngine/Core.hs

View workflow job for this annotation

GitHub Actions / windows-latest / ghc 8.8.4

• Overlapping instances for Alternative (P.Either String)

Check failure on line 450 in lib/DockerEngine/Core.hs

View workflow job for this annotation

GitHub Actions / macOS-latest / ghc 9.4.5

• Overlapping instances for Alternative (P.Either String)

Check failure on line 450 in lib/DockerEngine/Core.hs

View workflow job for this annotation

GitHub Actions / macOS-latest / ghc 9.4.5

• Overlapping instances for Alternative (P.Either String)

Check failure on line 450 in lib/DockerEngine/Core.hs

View workflow job for this annotation

GitHub Actions / macOS-latest / ghc 8.10.7

• Overlapping instances for Alternative (P.Either String)

Check failure on line 450 in lib/DockerEngine/Core.hs

View workflow job for this annotation

GitHub Actions / macOS-latest / ghc 8.10.7

• Overlapping instances for Alternative (P.Either String)

Check failure on line 450 in lib/DockerEngine/Core.hs

View workflow job for this annotation

GitHub Actions / macOS-latest / ghc 8.8.4

• Overlapping instances for Alternative (P.Either String)

Check failure on line 450 in lib/DockerEngine/Core.hs

View workflow job for this annotation

GitHub Actions / macOS-latest / ghc 8.8.4

• Overlapping instances for Alternative (P.Either String)

Check failure on line 450 in lib/DockerEngine/Core.hs

View workflow job for this annotation

GitHub Actions / macOS-latest / ghc 9.2.7

• Overlapping instances for Alternative (P.Either String)

Check failure on line 450 in lib/DockerEngine/Core.hs

View workflow job for this annotation

GitHub Actions / macOS-latest / ghc 9.2.7

• Overlapping instances for Alternative (P.Either String)

Check warning on line 450 in lib/DockerEngine/Core.hs

View workflow job for this annotation

GitHub Actions / macOS-latest / ghc 9.6.2

Orphan instance: instance Alternative (P.Either String)
empty = P.Left ""
P.Left _ <|> n = n
m <|> _ = m

-- | @_parseISO8601@
_readDateTime :: (TI.ParseTime t, Monad m, Alternative m, P.MonadFail m) => String -> m t
_readDateTime =
Expand Down
2 changes: 1 addition & 1 deletion stack.yaml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
resolver: lts-21.10
resolver: lts-22.6

nix:
packages:
Expand Down
8 changes: 4 additions & 4 deletions stack.yaml.lock
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
packages: []
snapshots:
- completed:
sha256: 1fc72fa74175fa3937b04c648229d601074183539a6f3d5cd49e99561873d79f
size: 640039
url: https://raw.githubusercontent.com/commercialhaskell/stackage-snapshots/master/lts/21/10.yaml
original: lts-21.10
sha256: 1b4c2669e26fa828451830ed4725e4d406acc25a1fa24fcc039465dd13d7a575
size: 714100
url: https://raw.githubusercontent.com/commercialhaskell/stackage-snapshots/master/lts/22/6.yaml
original: lts-22.6

0 comments on commit 8cf2e34

Please sign in to comment.