haskell-infra / hackage-trustees

Issue tracker for Hackage maintainance and trustee operations
https://hackage.haskell.org/packages/trustees/
42 stars 7 forks source link

haskell-language-extract needs another TH bump #323

Closed ysangkok closed 2 years ago

ysangkok commented 2 years ago

It was already bumped once according to the revisions list, but now GHC 9.2 is out with another TH version.

It is needed by test-framework-th, which has a lot of dependents: https://packdeps.haskellers.com/reverse/test-framework-th , among them tz, tzdata, monad-par, messagepack.

A PR has been lingering since June 2020: https://github.com/finnsson/template-helper/pull/13

phadej commented 2 years ago

It wasn't bumped, it was restricted. In particular it doesn't work with GHC-8.10, nor GHC-9.0 or 9.2:

% cabal build -w ghc-8.10.4 --allow-newer=template-haskell
Resolving dependencies...
Build profile: -w ghc-8.10.4 -O1
In order, the following will be built (use -v for more details):
 - language-haskell-extract-0.2.4 (lib:language-haskell-extract) (first run)
Warning: language-haskell-extract.cabal:57:30: version operators used. To use
version operators the package needs to specify at least 'cabal-version: >=
1.8'.
Configuring language-haskell-extract-0.2.4...
Preprocessing library for language-haskell-extract-0.2.4..
Building library for language-haskell-extract-0.2.4..
[1 of 1] Compiling Language.Haskell.Extract ( src/Language/Haskell/Extract.hs, /codetmp/language-haskell-extract-0.2.4/dist-newstyle/build/x86_64-linux/ghc-8.10.4/language-haskell-extract-0.2.4/build/Language/Haskell/Extract.o, /codetmp/language-haskell-extract-0.2.4/dist-newstyle/build/x86_64-linux/ghc-8.10.4/language-haskell-extract-0.2.4/build/Language/Haskell/Extract.dyn_o )

src/Language/Haskell/Extract.hs:28:30: error:
    • Couldn't match expected type ‘Maybe Exp’ with actual type ‘Exp’
    • In the expression: LitE $ StringL n
      In the first argument of ‘TupE’, namely
        ‘[LitE $ StringL n, VarE $ mkName n]’
      In the expression: TupE [LitE $ StringL n, VarE $ mkName n]
   |
28 |      let makePair n = TupE [ LitE $ StringL n , VarE $ mkName n]
   |                              ^^^^^^^^^^^^^^^^

src/Language/Haskell/Extract.hs:28:49: error:
    • Couldn't match expected type ‘Maybe Exp’ with actual type ‘Exp’
    • In the expression: VarE $ mkName n
      In the first argument of ‘TupE’, namely
        ‘[LitE $ StringL n, VarE $ mkName n]’
      In the expression: TupE [LitE $ StringL n, VarE $ mkName n]
   |
28 |      let makePair n = TupE [ LitE $ StringL n , VarE $ mkName n]
   |                                                 ^^^^^^^^^^^^^^^
ysangkok commented 2 years ago

Oh, sorry, I should have read the revision more carefully.

Bodigrim commented 2 years ago

test-framework ecosystem is on life support for many years. I strongly suggest to migrate to tasty, which amounts usually just to a change of imports.