Skip to content
Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 10 additions & 4 deletions .devcontainer/compose.yaml
Original file line number Diff line number Diff line change
@@ -1,15 +1,21 @@
{
"services": {
"devcontainer": {
"command": "sh -exc 'while sleep 1m; do :; done'",
"image": "public.ecr.aws/acilearning/haskell:9.6.2",
"command": "sleep infinity",
"image": "public.ecr.aws/acilearning/haskell:9.8.1",
"init": true,
"volumes": [
"..:/workspace",
"./volumes/cabal/cache:/home/vscode/.cache/cabal",
"./volumes/cabal/state:/home/vscode/.local/state/cabal",
"cabal-cache:/home/vscode/.cache/cabal",
"cabal-state:/home/vscode/.local/state/cabal",
],
"working_dir": "/workspace"
}
},
"volumes": {
"cabal-cache": null,
"cabal-state": {
"external": true
}
}
}
1 change: 1 addition & 0 deletions .devcontainer/devcontainer.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
}
},
"dockerComposeFile": "compose.yaml",
"initializeCommand": "docker volume create cabal-state",
"postCreateCommand": "cabal update",
"postStartCommand": "git config --global --add safe.directory \"$PWD\"",
"service": "devcontainer",
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/workflow.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,8 @@
"id": "haskell",
"uses": "haskell-actions/setup@v2",
"with": {
"cabal-version": "3.10.1.0",
"ghc-version": "9.6.2"
"cabal-version": "3.10.2.1",
"ghc-version": "9.8.1"
}
},
{
Expand Down Expand Up @@ -212,7 +212,7 @@
{
"uses": "haskell-actions/hlint-setup@v2",
"with": {
"version": 3.6.1
"version": 3.8
}
},
{
Expand Down
1 change: 0 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
/.devcontainer/volumes/
/.vscode/
/cabal.project.*
/dist-newstyle/
Expand Down
33 changes: 17 additions & 16 deletions monadoc.cabal
Original file line number Diff line number Diff line change
Expand Up @@ -30,14 +30,15 @@ flag pedantic
manual: True

common library
build-depends: base ^>=4.18.0.0
build-depends: base ^>=4.19.0.0
default-language: Haskell2010
ghc-options:
-Weverything -Wno-all-missed-specialisations -Wno-implicit-prelude
-Wno-missed-specialisations -Wno-missing-deriving-strategies
-Wno-missing-export-lists -Wno-missing-exported-signatures
-Wno-missing-kind-signatures -Wno-missing-safe-haskell-mode
-Wno-prepositive-qualified-module -Wno-safe -Wno-unsafe
-Wno-missing-kind-signatures -Wno-missing-role-annotations
-Wno-missing-safe-haskell-mode -Wno-prepositive-qualified-module
-Wno-safe -Wno-unsafe

if flag(pedantic)
ghc-options: -Werror
Expand All @@ -53,47 +54,47 @@ library
build-depends:
, aeson ^>=2.2.1.0
, async ^>=2.2.5
, bytestring ^>=0.11.4.0
, Cabal-syntax ^>=3.10.1.0
, bytestring ^>=0.12.0.2
, Cabal-syntax ^>=3.10.2.0
, case-insensitive ^>=1.2.1.0
, containers ^>=0.6.7
, containers ^>=0.6.8
, crypton ^>=0.31
, direct-sqlite ^>=2.3.28
, direct-sqlite ^>=2.3.29
, directory ^>=1.3.8.1
, exceptions ^>=0.10.7
, filepath ^>=1.4.100.1
, filepath ^>=1.4.100.4
, formatting ^>=7.2.0
, haddock-library ^>=1.11.0
, hashable ^>=1.4.3.0
, hspec ^>=2.11.7
, http-client ^>=0.7.15
, http-client ^>=0.7.16
, http-client-tls ^>=0.3.6.3
, http-types ^>=0.12.4
, lucid2 ^>=0.0.20230706
, memory ^>=0.18.0
, monad-control ^>=1.0.3.1
, monad-loops ^>=0.4.3
, network-uri ^>=2.6.4.2
, patrol ^>=1.0.0.6
, patrol ^>=1.0.0.7
, QuickCheck ^>=2.14.3
, random ^>=1.2.1.1
, resource-pool ^>=0.4.0.0
, saturn:{saturn, spec} ^>=1.0.0.3
, say ^>=0.1.0.1
, sqlite-simple ^>=0.4.18.2
, stm ^>=2.5.1.0
, sqlite-simple ^>=0.4.19.0
, stm ^>=2.5.2.1
, tar ^>=0.6.0.0
, temporary ^>=1.3
, text ^>=2.0.2
, text ^>=2.1
, time ^>=1.12.2
, transformers ^>=0.6.1.0
, uuid ^>=1.3.15
, vault ^>=0.3.1.5
, wai ^>=3.2.4
, wai-extra ^>=3.1.13.0
, wai-extra ^>=3.1.14
, wai-middleware-static ^>=0.9.2
, warp ^>=3.3.31
, witch ^>=1.2.0.3
, warp ^>=3.4.0
, witch ^>=1.2.0.4
, zlib ^>=0.6.3.0

default-extensions:
Expand Down
8 changes: 4 additions & 4 deletions source/library/Monadoc/Model/Blob.hs
Original file line number Diff line number Diff line change
Expand Up @@ -49,9 +49,9 @@ migrations =
]

new :: ByteString.ByteString -> Blob
new contents =
new c =
Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This seems like perhaps a GHC bug. The contents argument should be unambiguous here.

Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's a different module, but the warning I'm seeing is here: https://github.com/tfausak/monadoc/actions/runs/7648996583/job/20842674703#step:18:74

Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Blob
{ contents = contents,
hash = Hash.new contents,
size = ByteString.length contents
{ contents = c,
hash = Hash.new c,
size = ByteString.length c
}
6 changes: 3 additions & 3 deletions source/library/Monadoc/Type/ComponentId.hs
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,9 @@ data ComponentId = ComponentId
instance Witch.TryFrom String ComponentId where
tryFrom = Witch.maybeTryFrom $ \string -> do
let (before, after) = break ((==) ':') string
type_ <- Either.hush $ Witch.tryFrom before
name <- Either.hush . Witch.tryFrom $ drop 1 after
pure ComponentId {type_ = type_, name = name}
t <- Either.hush $ Witch.tryFrom before
n <- Either.hush . Witch.tryFrom $ drop 1 after
pure ComponentId {type_ = t, name = n}

instance Witch.TryFrom Text.Text ComponentId where
tryFrom = Witch.eitherTryFrom $ Witch.tryFrom . Witch.into @String
Expand Down