yesodweb / yesod

A RESTful Haskell web framework built on WAI.
http://www.yesodweb.com/
MIT License
2.64k stars 374 forks source link

Use crypton instead of cryptonite #1838

Closed ysangkok closed 4 months ago

ysangkok commented 4 months ago

Cryptonite has been archived on GitHub, and it has been forked to crypton. See

Tested using

nice cabal build yesod-static yesod-auth -c 'cryptonite<0' -w ghc-9.6.5 -c 'clientsession>=0.9.3.0' -c 'cprng-aes<0'

This depends on

Before submitting your PR, check that you've:

After submitting your PR:

ysangkok commented 4 months ago

@psibi It looks like you have maintainer rights for both yesod-auth and yesod-static. Would it be possible for you to review this?

psibi commented 4 months ago

@ysangkok Looks good to me. Can you see why the CI is failing ?

ysangkok commented 4 months ago

@psibi Tests are on par with master now, that is, they only fail on MacOS, for unrelated reasons.

psibi commented 4 months ago

@ysangkok It looks like that it would require some changes to stack.yaml file for the CI to pass: https://github.com/yesodweb/yesod/actions/runs/9946180395/job/27484737340?pr=1838

ysangkok commented 4 months ago

All versions of crypton contain

    if impl(ghc <8.8)
        buildable: False

So the builds for lts-14 can't use crypton.

I see two options:

  1. make the dependency conditional depending on GHC version. So we require cryptonite for ghc<8.8.
  2. remove compatibility for GHC 8.6 and below
psibi commented 4 months ago

remove compatibility for GHC 8.6 and below

I would lean towards this. CC: @snoyberg if he has any objections.

snoyberg commented 4 months ago

Agreed