yesodweb / yesodweb/persistent

2.14.6.3: No instance for ‘NFData Text’ arising from a use of ‘rnf’

Open
#1,557 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Haskell
Stars
486
Forks
306
PR merge metrics
No merged PRs in 30d

Description

[ 3 of 46] Compiling Database.Persist.PersistValue ( Database/Persist/PersistValue.hs, dist/build/Database/Persist/PersistValue.o, dist/build/Database/Persist
/PersistValue.dyn_o )

Database/Persist/PersistValue.hs:78:24: error: [GHC-39999]
• No instance for ‘NFData Text’ arising from a use of ‘rnf’
• In the expression: rnf txt
In a case alternative: PersistText txt -> rnf txt
In the expression:
case val of
PersistText txt -> rnf txt
PersistByteString bs -> rnf bs
PersistInt64 i -> rnf i
PersistDouble d -> rnf d
PersistRational q -> rnf q
PersistBool b -> rnf b
PersistDay d -> rnf d
PersistTimeOfDay t -> rnf t
PersistUTCTime t -> rnf t
PersistNull -> ()
PersistList vals -> rnf vals
PersistMap vals -> rnf vals
PersistObjectId bs -> rnf bs
PersistArray vals -> rnf vals
PersistLiteral_ ty bs -> ty seq rnf bs
|
78 | PersistText txt -> rnf txt
| ^^^

GHC 9.8.2

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reproducing the GHC 9.8.2 build failure in Database/Persist/PersistValue.hs, focusing on line 78 and the PersistText branch. Determine what change is needed for the reported NFData Text error, then rerun the build to confirm the error is resolved.

Written by the indexing model from the issue text.

Assessment

Tech stack
haskell
Domain
databases
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
30/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.