From 11a6ff77067a7b9eec3f1c15412d7143cb85a047 Mon Sep 17 00:00:00 2001 From: Florian Klink Date: Wed, 5 Jun 2024 23:25:34 +0300 Subject: docs(tvix/docs/TODO): document attempt to add more granular errors Change-Id: I46f99d15a4ce9c98dcdad822d3032bda3b09c12f Reviewed-on: https://cl.tvl.fyi/c/depot/+/11754 Reviewed-by: flokli Autosubmit: flokli Reviewed-by: Simon Hauser Tested-by: BuildkiteCI --- tvix/docs/src/TODO.md | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'tvix') diff --git a/tvix/docs/src/TODO.md b/tvix/docs/src/TODO.md index 20ad07eb2505..66d90aaa9494 100644 --- a/tvix/docs/src/TODO.md +++ b/tvix/docs/src/TODO.md @@ -66,6 +66,14 @@ which are supposed to be skipped. This is quite primitive. We should have individual error types for BS, DS, PS. Maybe these should have some generics to still be able to carry errors from the underlying backend, similar to `IngestionError`. + There was an attempt to give PS separate error types (cl/11695), but this + ended up very verbose. + Every error had to be boxed, and a possible additional message be added. Some + errors that didn't wrap another underlying errors were hard to construct, too + (requiring the addition of errors). All of this without even having added + proper backtrace support, which would be quite helpful in store hierarchies. + `anyhow`'s `.context()` gives us most of this out of the box. Maybe we can + use that, using enums rather than `&'static str` as context in some cases? ## Fixes towards correctness - `rnix` only supports string source files, but `NixString` uses bytes (and Nix -- cgit 1.4.1