Skip to content

Update to crypton >= 1.1.0 and ram instead of memory#137

Merged
frasertweedale merged 2 commits into
frasertweedale:masterfrom
sumo:master
Jun 6, 2026
Merged

Update to crypton >= 1.1.0 and ram instead of memory#137
frasertweedale merged 2 commits into
frasertweedale:masterfrom
sumo:master

Conversation

@sumo

@sumo sumo commented Mar 13, 2026

Copy link
Copy Markdown
Contributor

The latest crypton (1.1.0) has now switched to ram instead of memory.

@georgefst

georgefst commented Mar 19, 2026

Copy link
Copy Markdown

Note that builds are currently failing due to the upper bound being too lax, and crypton-1.1.0 switching to ram:

[ 1 of 18] Compiling Crypto.JOSE.AESKW
src/Crypto/JOSE/AESKW.hs:53:11: error: [GHC-39999]
    • Could not deduce ‘ram-0.21.1:Data.ByteArray.Types.ByteArray
                          ScrubbedBytes’
        arising from a use of ‘ecbEncrypt’
      from the context: BlockCipher128 cipher
        bound by the type signature for:
                   aesKeyWrapStep :: forall cipher.
                                     BlockCipher128 cipher =>
                                     cipher -> Ptr Word64 -> (Int, Int) -> StateT Word64 IO ()
        at src/Crypto/JOSE/AESKW.hs:(42,1)-(47,24)
    • In the expression: ecbEncrypt cipher m
      In an equation for ‘b’: b = ecbEncrypt cipher m
      In a stmt of a 'do' block: let b = ecbEncrypt cipher m
   |
53 |   let b = ecbEncrypt cipher m
   |           ^^^^^^^^^^

This PR presumably fixes that, although another workaround otherwise for now is to add to a cabal.project:

constraints:
  crypton == 1.0.7,

Really, there should be Hackage revisions for all older versions of jose, specifying crypton < 1.1.

Comment thread jose.cabal Outdated
, crypton >= 0.31
, memory >= 0.7
, crypton >= 1.1.0
, ram < 0.22

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

This should be changed to >= 0.22

Set crypton upper bound to avoid plan failure with crypton >= 1.1.0,
which moved from `memory` to `ram` package.
Co-Authored-By: Fraser Tweedale <frase@frase.id.au>
@frasertweedale
frasertweedale merged commit d00ad17 into frasertweedale:master Jun 6, 2026
4 of 5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants