hledger/hledger-lib/Hledger
Simon Michael 45d5fd7963 imp: show a clearer error message on unicode en/decoding failures [#73]
A very long-awaited improvement: for unicode exceptions, and I/O
exceptions which look like they were caused by a unicode error
(usually text decoding failure), our error message now includes
an explanation and advice on what to do.

Currently this uses the GHC.IO.Encoding API, which is not ideal:
"The API of this module is unstable and not meant to be consumed by
the general public. If you absolutely must depend on it, make sure to
use a tight upper bound, e.g., base < 4.X rather than base < 5,
because the interface can change rapidly without much warning."

Also it relies on scanning for patterns in GHC's various
unicode-related error messages, which may not be complete and could
change in future. To do: try the encoding package's IO helpers,
perhaps they give more specific exceptions.
2025-04-25 08:57:07 -10:00
..
Data lib: journalCommoditiesUsed 2025-04-23 21:43:30 -10:00
Read ;doc: note check-related bug in rawOptsToInputOpts [#2377] 2025-04-24 10:44:34 -10:00
Reports lib: Hledger.Data.Dates: parsedateM -> parsedate 2025-04-22 10:40:41 -10:00
Utils imp: show a clearer error message on unicode en/decoding failures [#73] 2025-04-25 08:57:07 -10:00
Write dev: refactor Hledger.Write.Html etc, reducing Lucid references 2025-01-25 11:53:51 -10:00
Data.hs lib: add Hledger.Data.Currency, currencySymbolToCode, currencyCodeToSymbol 2024-10-11 14:56:03 -10:00
Query.hs feat: any:, all: queries allow more powerful transaction matching 2025-04-18 14:06:45 -10:00
Read.hs lib: Hledger.Read: more ways to read the default journal 2025-04-22 18:50:42 -10:00
Reports.hs cln: tests: Remove test and tests, which are just aliases for testCase 2021-08-30 16:32:19 -10:00
Utils.hs dev: fix warnings with ghc 9.10 / base 4.20 2024-09-30 17:20:13 -10:00