Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
haskell-gargantext
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
199
Issues
199
List
Board
Labels
Milestones
Merge Requests
12
Merge Requests
12
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
gargantext
haskell-gargantext
Commits
8ce6fba6
Verified
Commit
8ce6fba6
authored
Sep 12, 2024
by
Przemyslaw Kaminski
1
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[ghc] more deps fixes, also test small fix
parent
95f311fb
Pipeline
#6631
canceled with stages
Changes
8
Pipelines
1
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
807 additions
and
104 deletions
+807
-104
README.md
README.md
+4
-0
update-project-dependencies
bin/update-project-dependencies
+2
-2
cabal.project
cabal.project
+2
-14
cabal.project.freeze
cabal.project.freeze
+623
-0
gargantext.cabal
gargantext.cabal
+2
-16
ReverseProxy.hs
src/Gargantext/MicroServices/ReverseProxy.hs
+8
-8
stack.yaml
stack.yaml
+153
-57
Jobs.hs
test/Test/Utils/Jobs.hs
+13
-7
No files found.
README.md
View file @
8ce6fba6
...
...
@@ -166,6 +166,10 @@ If you want to see the detailed build info for a given dependency:
cabal v2-build
-v
servant-server
```
Also, you might use the
`-Wunused-packages`
GHC option, to get a
warning about unused packages (make sure though you build all targets
with
`cabal v2-build all`
).
Also, here is a relevant discussion:
https://discourse.haskell.org/t/whats-your-workflow-to-update-cabal-dependencies/9475
...
...
bin/update-project-dependencies
View file @
8ce6fba6
...
...
@@ -18,8 +18,8 @@ fi
# with the `sha256sum` result calculated on the `cabal.project` and
# `cabal.project.freeze`. This ensures the files stay deterministic so that CI
# cache can kick in.
expected_cabal_project_hash
=
"
641c87fb990ef95f861805e11c76663f075516af845c5dab458bf82b3ba5fd7d
"
expected_cabal_project_freeze_hash
=
"
6ca9d2c298827a05d873e30aaac5db3cf6648c7ca9118f13f1b109c13479f38b
"
expected_cabal_project_hash
=
"
967fee2ed28f46b12a629ad9821301854d3159975b7297653e50d7fc1f3b8919
"
expected_cabal_project_freeze_hash
=
"
af825192f1ec47b07e6001dd2556b59991c9e6c50094dc732ee933a41f0dc9bd
"
cabal
--store-dir
=
$STORE_DIR
v2-build
--dry-run
...
...
cabal.project
View file @
8ce6fba6
...
...
@@ -90,7 +90,7 @@ source-repository-package
source
-
repository
-
package
type
:
git
location
:
https
://
gitlab
.
iscpif
.
fr
/
gargantext
/
crawlers
/
epo
-
proxy
-
api
.
git
tag
:
9225
d046083853200b9045c8d71161e6a234fc5c
tag
:
cf4e5004f3b002bdef3fcab95e3559d65cdcd858
source
-
repository
-
package
type
:
git
...
...
@@ -110,7 +110,7 @@ source-repository-package
source
-
repository
-
package
type
:
git
location
:
https
://
gitlab
.
iscpif
.
fr
/
gargantext
/
crawlers
/
openalex
.
git
tag
:
d2df0130575cfd32d6863d77e2ce34c48a1c32fa
tag
:
4
eec15855207dc74afc75b94c3764eede4de7b55
source
-
repository
-
package
type
:
git
...
...
@@ -199,8 +199,6 @@ source-repository-package
tag
:
02f5
ed9ee2d6cce45161addf945b88bc6adf9059
allow
-
newer
:
accelerate
-
arithmetic
:
accelerate
,
MissingH
:
base
...
...
@@ -210,10 +208,6 @@ allow-newer:
,
crawlerISTEX
:
servant
,
crawlerPubMed
:
servant
,
crawlerPubMed
:
servant
-
client
-
core
,
epo
-
api
-
client
:
base
,
epo
-
api
-
client
:
aeson
,
epo
-
api
-
client
:
servant
,
epo
-
api
-
client
:
text
,
iso639
:
aeson
,
iso639
:
text
,
morpheus
-
graphql
-
app
:
text
...
...
@@ -224,9 +218,6 @@ allow-newer:
,
morpheus
-
graphql
-
server
:
text
,
morpheus
-
graphql
-
subscriptions
:
text
,
morpheus
-
graphql
:
text
,
openalex
:
servant
,
openalex
:
servant
-
client
-
core
,
openalex
:
time
,
servant
-
client
:
servant
,
servant
-
client
:
servant
-
client
-
core
,
servant
-
ekg
:
base
...
...
@@ -240,11 +231,8 @@ allow-newer:
,
stemmer
:
base
allow
-
older
:
aeson
:
hashable
,
crawlerHAL
:
servant
-
client
,
epo
-
api
-
client
:
http
-
client
-
tls
,
haskell
-
throttle
:
time
,
hsparql
:
rdf4h
,
openalex
:
http
-
client
-
tls
,
openalex
:
vector
package
gargantext
ghc
-
options
:
-
fwrite
-
ide
-
info
-
hiedir
=
".stack-work/hiedb"
...
...
cabal.project.freeze
0 → 100644
View file @
8ce6fba6
This diff is collapsed.
Click to expand it.
gargantext.cabal
View file @
8ce6fba6
...
...
@@ -472,8 +472,7 @@ library
if flag(no-phylo-debug-logs)
cpp-options: -DNO_PHYLO_DEBUG_LOGS
build-depends:
HSvm ^>= 0.1.1.3.22
, KMP ^>= 0.2.0.0
KMP ^>= 0.2.0.0
, MissingH ^>= 1.4.3.0
, MonadRandom ^>= 0.6
, QuickCheck ^>= 2.14.2
...
...
@@ -502,7 +501,6 @@ library
, crawlerPubMed
, cron ^>= 0.7.0
, data-time-segment ^>= 0.1.0.0
, deepseq ^>= 1.4.4.0
, deferred-folds >= 0.9.18 && < 0.10
, directory ^>= 1.3.6.0
, discrimination >= 0.5
...
...
@@ -516,7 +514,6 @@ library
, filepath ^>= 1.4.2.1
, fmt
, formatting ^>= 7.2.0
, full-text-search ^>= 0.2.1.4
, fullstop ^>= 0.1.4
, gargantext-graph >=0.1.0.0
, gargantext-prelude
...
...
@@ -530,11 +527,10 @@ library
, http-api-data >= 0.5 && < 0.6
, http-client ^>= 0.7.14
, http-client-tls == 0.3.6.1
, http-conduit
^>= 2.3.8
, http-conduit
>= 2.3.8 && < 2.3.9
, http-media ^>= 0.8.0.0
, http-types ^>= 0.12.3
, http-reverse-proxy >= 0.6.1.0
, hxt ^>= 9.3.1.22
, ini ^>= 0.4.1
, insert-ordered-containers ^>= 0.2.5.1
, iso639 ^>= 0.1.0.3
...
...
@@ -542,8 +538,6 @@ library
, json-stream ^>= 0.4.2.4
, lens >= 5.2.2 && < 5.3
, lens-aeson < 1.3
, lifted-base ^>= 0.2.3.12
, listsafe ^>= 0.1.0.1
, matrix ^>= 0.3.6.1
, mime-mail >= 0.5.1
, monad-control ^>= 1.0.3.1
...
...
@@ -553,13 +547,11 @@ library
, morpheus-graphql-subscriptions >= 0.24.3 && < 0.25
, mtl ^>= 2.2.2
, nanomsg-haskell >= 0.2.4 && < 0.3
, natural-transformation ^>= 0.4
, network >= 3.1.4.0
, network-uri ^>= 2.6.4.1
, opaleye ^>= 0.9.6.1
, opaleye-textsearch >= 0.2.0.0
, openalex
, pandoc ^>= 3.0.1
, parallel ^>= 3.2.2.0
, parsec ^>= 3.1.14.0
, patches-class ^>= 0.1.0.1
...
...
@@ -586,7 +578,6 @@ library
, servant-client-core >= 0.20 && < 0.21
, servant-ekg ^>= 0.3.1
, servant-job >= 0.2.0.0
, servant-multipart ^>= 0.12.1
, servant-routes < 0.2
, servant-server >= 0.18.3 && < 0.21
, servant-swagger ^>= 1.2
...
...
@@ -602,7 +593,6 @@ library
, stm-containers >= 1.2.0.3 && < 1.3
, stringsearch >= 0.3.6.6
, swagger2 ^>= 2.8.7
, taggy-lens ^>= 0.1.2
, tagsoup ^>= 0.14.8
, template-haskell ^>= 2.19.0.0
, temporary ^>= 1.3
...
...
@@ -624,7 +614,6 @@ library
, wai-cors ^>= 0.2.7
, wai-extra ^>= 3.1.8
, wai-util >= 0.8
, wai-websockets ^>= 3.0.1.2
, warp ^>= 3.3.20
, websockets ^>= 0.12.7.3
, wreq ^>= 0.5.3.3
...
...
@@ -667,7 +656,6 @@ executable gargantext-cli
, cryptohash ^>= 0.11.9
, directory ^>= 1.3.6.0
, extra ^>= 1.7.9
, full-text-search ^>= 0.2.1.4
, gargantext
, gargantext-prelude
, ini ^>= 0.4.1
...
...
@@ -704,7 +692,6 @@ executable gargantext-server
cassava ^>= 0.5.2.0
, containers ^>= 0.6.5.1
, extra ^>= 1.7.9
, full-text-search ^>= 0.2.1.4
, gargantext
, gargantext-prelude
, ini ^>= 0.4.1
...
...
@@ -892,7 +879,6 @@ benchmark garg-bench
Paths_gargantext
build-depends: base
, bytestring ^>= 0.11.5.2
, deepseq
, gargantext
, gargantext-prelude
, tasty-bench
...
...
src/Gargantext/MicroServices/ReverseProxy.hs
View file @
8ce6fba6
...
...
@@ -51,7 +51,7 @@ import Network.Wai
import
Network.Wai.Util
(
redirect'
)
import
Servant
hiding
(
Header
)
import
Servant.Auth.Server
import
Servant.Auth.Server.Internal.AddSetCookie
import
Servant.Auth.Server.Internal.AddSetCookie
()
import
Servant.Auth.Swagger
()
import
Servant.Client.Core.BaseUrl
import
Servant.Server.Generic
...
...
@@ -59,13 +59,13 @@ import Text.RE.Replace hiding (Capture)
import
Text.RE.TDFA.ByteString
-- See https://github.com/haskell-servant/servant/issues/1601#issue-1338013029
instance
{-# OVERLAPPING #-}
(
AddSetCookies
(
'S
n
)
a
a
,
AddSetCookies
(
'S
n
)
b
b'
)
=>
AddSetCookies
(
'S
n
)
(
a
:<|>
b
)
(
a
:<|>
b'
)
where
addSetCookies
cookies
(
a
:<|>
b
)
=
addSetCookies
cookies
a
:<|>
addSetCookies
cookies
b
--
--
See https://github.com/haskell-servant/servant/issues/1601#issue-1338013029
--
instance {-# OVERLAPPING #-}
--
( AddSetCookies ('S n) a a
--
, AddSetCookies ('S n) b b'
--
)
--
=> AddSetCookies ('S n) (a :<|> b) (a :<|> b') where
--
addSetCookies cookies ( a :<|> b) = addSetCookies cookies a :<|> addSetCookies cookies b
--
-- Types
...
...
stack.yaml
View file @
8ce6fba6
#"allow-newer": tru
e
"
allow-newer"
:
fals
e
"
extra-deps"
:
-
"
HSvm-0.1.1.3.22
"
-
"
JuicyPixels-3.3.9
"
-
"
KMP-0.2.0.0"
-
"
MissingH-1.4.3.0"
-
"
MissingH-1.4.3.1"
-
"
OneTuple-0.4.2"
-
"
aeson-pretty-0.8.10"
-
"
alex-3.5.1.0"
-
"
ansi-terminal-1.0.2"
-
"
assoc-1.1.1"
-
"
async-2.2.5"
-
"
atomic-primops-0.8.8"
-
"
barbies-2.1.1.0"
-
"
base-compat-0.13.1"
-
"
base-compat-batteries-0.13.1"
-
"
base-orphans-0.9.2"
-
"
base64-1.0"
-
"
bifunctors-5.6.2"
-
"
binary-orphans-1.0.5"
-
"
blaze-html-0.9.2.0"
-
"
boring-0.2.2"
-
"
bzlib-conduit-0.3.0.3"
-
"
cabal-doctest-1.0.10"
-
"
cassava-0.5.3.2"
-
"
cassava-conduit-0.6.6"
-
"
cborg-0.2.10.0"
-
"
concurrent-output-1.10.21"
-
"
conduit-1.3.6"
-
"
criterion-measurement-0.2.2.0"
-
"
cron-0.7.1"
-
"
crypton-1.0.0"
-
"
crypton-x509-1.7.7"
-
"
data-fix-0.3.4"
-
"
dec-0.0.6"
-
"
deferred-folds-0.9.18.6"
-
"
full-text-search-0.2.1.4"
-
"
digest-0.0.2.1"
-
"
double-conversion-2.0.5.0"
-
"
extra-1.7.16"
-
"
fast-logger-3.2.3"
-
"
fgl-5.8.2.0"
-
"
file-embed-0.0.16.0"
-
"
file-embed-lzma-0.1"
-
"
foldl-1.4.17"
-
"
free-5.2"
-
"
fullstop-0.1.4"
-
"
hgal-2.0.0.2"
-
"
graphviz-2999.20.2.0"
-
"
hashable-1.4.4.0"
-
"
haskell-src-meta-0.8.14"
-
"
hedgehog-1.5"
-
"
hslogger-1.3.1.1"
-
"
hsparql-0.3.8"
-
"
hspec-2.11.1"
-
"
hspec-core-2.11.1"
-
"
hspec-discover-2.11.1"
-
"
hspec-expectations-0.8.3"
-
"
hspec-2.11.9"
-
"
hspec-api-2.11.9"
-
"
hspec-core-2.11.9"
-
"
hspec-discover-2.11.9"
-
"
hspec-expectations-0.8.4"
-
"
http-accept-0.2"
-
"
http-api-data-0.5.1"
-
"
http-conduit-2.3.8.3"
-
"
http-types-0.12.4"
-
"
http2-5.0.1"
-
"
indexed-traversable-0.1.4"
-
"
invariant-0.6.3"
-
"
iproute-1.7.14"
-
"
jose-0.10.0.1"
-
"
json-stream-0.4.6.0"
-
"
kan-extensions-5.2.6"
-
"
language-c-0.9.3"
-
"
libyaml-0.1.4"
-
"
libyaml-clib-0.2.5"
-
"
lifted-async-0.10.2.5"
-
"
logict-0.8.1.0"
-
"
lzma-0.0.1.1"
-
"
math-functions-0.3.4.4"
-
"
matrix-0.3.6.3"
-
"
megaparsec-9.6.1"
-
"
microlens-th-0.4.3.15"
-
"
mono-traversable-1.0.17.0"
-
"
monoid-extras-0.6.3"
-
"
morpheus-graphql-0.24.3"
-
"
morpheus-graphql-app-0.24.3"
-
"
morpheus-graphql-client-0.24.3"
...
...
@@ -21,25 +85,78 @@
-
"
morpheus-graphql-core-0.24.3"
-
"
morpheus-graphql-server-0.24.3"
-
"
morpheus-graphql-subscriptions-0.24.3"
-
"
opaleye-0.9.6.1"
-
"
mwc-random-0.15.1.0"
-
"
network-control-0.0.2"
-
"
old-time-1.1.0.4"
-
"
ordered-containers-0.2.4"
-
"
os-string-2.0.6"
-
"
password-3.0.4.0"
-
"
postgres-options-0.2.2.0"
-
"
primitive-0.7.4.0"
-
"
primitive-extras-0.10.2"
-
"
primitive-unlifted-2.1.0.0"
-
"
protolude-0.3.4"
-
"
psqueues-0.2.8.0"
-
"
rake-0.0.1"
-
"
random-1.2.1"
-
"
random-1.2.1
.2
"
-
"
recover-rtti-0.4.3"
-
"
servant-0.20.1"
-
"
servant-auth-server-0.4.8.0"
-
"
servant-auth-swagger-0.2.10.2"
-
"
servant-client-core-0.20"
-
"
reflection-2.1.8"
-
"
resourcet-1.3.0"
-
"
safe-0.3.21"
-
"
serialise-0.2.6.1"
-
"
servant-0.20.2"
-
"
servant-auth-0.4.2.0"
-
"
servant-auth-client-0.4.2.0"
-
"
servant-auth-server-0.4.9.0"
-
"
servant-auth-swagger-0.2.11.0"
-
"
servant-client-core-0.20.2"
-
"
servant-ekg-0.3.1"
-
"
servant-flatten-0.2"
-
"
servant-server-0.20"
-
"
servant-swagger-1.2"
-
"
servant-server-0.20.2"
-
"
servant-swagger-1.2.1"
-
"
servant-swagger-ui-0.3.5.5.0.1"
-
"
singleton-bool-0.1.8"
-
"
singletons-3.0.3"
-
"
some-1.0.6"
-
"
split-0.2.5"
-
"
stemmer-0.5.2"
-
"
stm-containers-1.2.1"
-
"
stm-hamt-1.2.1"
-
"
swagger2-2.8.9"
-
"
tagged-0.8.8"
-
"
taggy-0.2.1"
-
"
taggy-lens-0.1.2"
-
"
vector-0.12.3.0"
-
"
tasty-1.5"
-
"
tasty-bench-0.4"
-
"
tasty-hspec-1.2.0.4"
-
"
tasty-hunit-0.10.2"
-
"
tasty-quickcheck-0.11"
-
"
text-short-0.1.6"
-
"
th-compat-0.1.5"
-
"
these-1.2.1"
-
"
time-compat-1.9.7"
-
"
type-equality-1.0.1"
-
"
typed-process-0.2.12.0"
-
"
unicode-collation-0.1.3.6"
-
"
unix-compat-0.7.2"
-
"
unix-time-0.4.15"
-
"
unordered-containers-0.2.20"
-
"
utility-ht-0.0.17.2"
-
"
uuid-1.3.16"
-
"
uuid-types-1.0.6"
-
"
validity-0.12.1.0"
-
"
vector-0.12.3.1"
-
"
vector-algorithms-0.9.0.2"
-
"
wai-3.2.4"
-
"
wai-app-static-3.1.9"
-
"
wai-extra-3.1.15"
-
"
wai-logger-2.4.1"
-
"
wai-util-0.8"
-
"
warp-3.3.31"
-
"
wreq-0.5.4.3"
-
"
zip-2.0.1"
-
"
zip-archive-0.4.3.2"
-
"
zlib-0.7.1.0"
-
commit
:
2b5d69448557e89002c0179ea1aaf59bb757a6e3
git
:
"
https://github.com/AccelerateHS/accelerate-llvm.git"
subdirs
:
...
...
@@ -88,7 +205,7 @@
git
:
"
https://github.com/boolexpr/boolexpr.git"
subdirs
:
-
.
-
commit
:
8fff32a43df743c8c83428a86dd566a0936a4fba
-
commit
:
1790fdf9138970dde0dbabf8b270698145a4a88c
git
:
"
https://github.com/chessai/eigen.git"
subdirs
:
-
.
...
...
@@ -124,7 +241,7 @@
git
:
"
https://gitlab.iscpif.fr/gargantext/crawlers/arxiv-api.git"
subdirs
:
-
.
-
commit
:
9225d046083853200b9045c8d71161e6a234fc5c
-
commit
:
cf4e5004f3b002bdef3fcab95e3559d65cdcd858
git
:
"
https://gitlab.iscpif.fr/gargantext/crawlers/epo-proxy-api.git"
subdirs
:
-
.
...
...
@@ -140,7 +257,7 @@
git
:
"
https://gitlab.iscpif.fr/gargantext/crawlers/istex.git"
subdirs
:
-
.
-
commit
:
d2df0130575cfd32d6863d77e2ce34c48a1c32fa
-
commit
:
4eec15855207dc74afc75b94c3764eede4de7b55
git
:
"
https://gitlab.iscpif.fr/gargantext/crawlers/openalex.git"
subdirs
:
-
.
...
...
@@ -218,11 +335,10 @@ flags:
"
lib-only"
:
false
"
ansi-terminal"
:
example
:
false
"
win32-2-13-1"
:
false
"
ansi-wl-pprint"
:
example
:
false
assoc
:
tagged
:
tru
e
tagged
:
fals
e
async
:
bench
:
false
"
atomic-primops"
:
...
...
@@ -233,7 +349,6 @@ flags:
"
base-4-8"
:
true
"
old-base"
:
false
bifunctors
:
semigroups
:
true
tagged
:
true
bitvec
:
simd
:
true
...
...
@@ -244,8 +359,6 @@ flags:
c2hs
:
base3
:
true
regression
:
false
cassava
:
"
bytestring--lt-0_10_4"
:
false
"
cassava-conduit"
:
small_base
:
true
cborg
:
...
...
@@ -254,9 +367,6 @@ flags:
"
bytestring-builder"
:
false
"
cipher-aes"
:
support_aesni
:
true
citeproc
:
executable
:
false
icu
:
false
clock
:
llvm
:
false
cmdargs
:
...
...
@@ -300,6 +410,12 @@ flags:
support_sse
:
false
use_target_attributes
:
true
digest
:
have_arm64_crc32c
:
false
have_builtin_prefetch
:
false
have_mm_prefetch
:
false
have_sse42
:
false
have_strong_getauxval
:
false
have_weak_getauxval
:
false
"
pkg-config"
:
true
distributive
:
semigroups
:
true
...
...
@@ -316,9 +432,7 @@ flags:
"
foldable1-classes-compat"
:
tagged
:
true
formatting
:
"
no-double-conversion"
:
true
"
full-text-search"
:
"
build-search-demo"
:
false
"
no-double-conversion"
:
false
gargantext
:
"
no-phylo-debug-logs"
:
false
"
test-crypto"
:
false
...
...
@@ -354,7 +468,7 @@ flags:
devel
:
false
h2spec
:
false
hxt
:
"
network-uri"
:
tru
e
"
network-uri"
:
fals
e
profile
:
false
"
hxt-charproperties"
:
profile
:
false
...
...
@@ -408,6 +522,8 @@ flags:
"
mtl-compat"
:
"
two-point-one"
:
false
"
two-point-two"
:
false
"
mwc-random"
:
benchpapi
:
false
network
:
devel
:
false
"
optics-core"
:
...
...
@@ -416,8 +532,6 @@ flags:
process
:
true
"
optparse-simple"
:
"
build-example"
:
false
pandoc
:
embed_data_files
:
false
"
parser-combinators"
:
dev
:
false
parsers
:
...
...
@@ -427,6 +541,8 @@ flags:
password
:
argon2
:
true
bcrypt
:
true
crypton
:
false
cryptonite
:
false
pbkdf2
:
true
scrypt
:
true
"
postgresql-libpq"
:
...
...
@@ -483,10 +599,6 @@ flags:
"
simple-sendfile"
:
"
allow-bsd"
:
true
fallback
:
false
skylighting
:
executable
:
false
"
skylighting-core"
:
executable
:
false
some
:
"
newtype-unsafe"
:
true
splitmix
:
...
...
@@ -502,21 +614,15 @@ flags:
tasty
:
unix
:
true
"
tasty-bench"
:
debug
:
false
tasty
:
true
"
tasty-golden"
:
"
build-example"
:
false
texmath
:
executable
:
false
server
:
false
"
text-format"
:
developer
:
false
"
text-metrics"
:
dev
:
false
"
text-short"
:
asserts
:
false
"
time-compat"
:
"
old-locale"
:
false
"
time-locale-compat"
:
"
old-locale"
:
false
tls
:
...
...
@@ -536,16 +642,6 @@ flags:
"
unicode-collation"
:
doctests
:
false
executable
:
false
"
unicode-data"
:
ucd2haskell
:
false
"
unicode-transforms"
:
"
bench-show"
:
false
dev
:
false
"
has-icu"
:
false
"
has-llvm"
:
false
"
use-gauge"
:
false
"
unix-compat"
:
"
old-time"
:
false
"
unordered-containers"
:
debug
:
false
"
uri-bytestring"
:
...
...
@@ -601,8 +697,8 @@ flags:
executable
:
false
zlib
:
"
bundled-c-zlib"
:
false
"
non-blocking-ffi"
:
fals
e
"
pkg-config"
:
fals
e
"
non-blocking-ffi"
:
tru
e
"
pkg-config"
:
tru
e
zstd
:
standalone
:
true
packages
:
...
...
test/Test/Utils/Jobs.hs
View file @
8ce6fba6
...
...
@@ -362,19 +362,24 @@ testFetchJobStatusNoContention = do
testMarkProgress
::
IO
()
testMarkProgress
=
do
myEnv
<-
newTestEnv
evts
<-
newTBQueueIO
7
-- evts <- newTBQueueIO 7
evts
<-
newTVarIO
[]
let
getStatus
hdl
=
do
liftIO
$
threadDelay
100
_000
st
<-
getLatestJobStatus
hdl
liftIO
$
atomically
$
writeTBQueue
evts
st
-- liftIO $ atomically $ writeTBQueue evts st
liftIO
$
atomically
$
modifyTVar
evts
(
\
xs
->
st
:
xs
)
readAllEvents
=
do
-- We will get thread blocking if there is ANY error in the job
-- Hence we assert the `readAllEvents` test doesn't take too long
mRet
<-
timeout
2
_000_000
$
atomically
$
do
allEventsArrived
<-
isFullTBQueue
evts
mRet
<-
timeout
1
_000_000
$
atomically
$
do
-- allEventsArrived <- isFullTBQueue evts
evts'
<-
readTVar
evts
-- STM retry if things failed
check
allEventsArrived
flushTBQueue
evts
-- check allEventsArrived
check
(
length
evts'
==
7
)
-- flushTBQueue evts
return
evts'
return
$
fromMaybe
[]
mRet
withJob_
myEnv
$
\
hdl
_input
->
do
...
...
@@ -401,7 +406,8 @@ testMarkProgress = do
getStatus
hdl
[
jl0
,
jl1
,
jl2
,
jl3
,
jl4
,
jl5
,
jl6
]
<-
readAllEvents
evts'
<-
readAllEvents
let
[
jl0
,
jl1
,
jl2
,
jl3
,
jl4
,
jl5
,
jl6
]
=
evts'
-- Check the events are what we expect
jl0
`
shouldBe
`
JobLog
{
_scst_succeeded
=
Just
0
...
...
Przemyslaw Kaminski
@cgenie
mentioned in commit
5660aec0
·
Oct 08, 2024
mentioned in commit
5660aec0
mentioned in commit 5660aec07ec5a0a0a5468f440092c1a8f57a864e
Toggle commit list
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment