tweag / topiary

https://topiary.tweag.io/
MIT License
575 stars 29 forks source link

The error message when trying to override the config file is hard to understand #788

Closed nbacquey closed 2 weeks ago

nbacquey commented 2 weeks ago

Describe the bug

$ topiary fmt -C languages.ncl sample.sh
[2024-11-04T15:16:59Z ERROR topiary] Nickel error: EvalError(MergeIncompatibleArgs { left_arg: RichTerm { term: SharedTerm { shared: Str(NickelString("d1a1a3fe7189fdab5bd29a54d1df4a5873db5cb1")) }, pos: Inherited(RawSpan { src_id: FileId(1), start: ByteIndex(167), end: ByteIndex(209) }) }, right_arg: RichTerm { term: SharedTerm { shared: Str(NickelString("e1a1a3fe7189fdab5bd29a54d1df4a5873db5cb1")) }, pos: Inherited(RawSpan { src_id: FileId(5), start: ByteIndex(167), end: ByteIndex(209) }) }, merge_label: MergeLabel { span: RawSpan { src_id: FileId(2), start: ByteIndex(0), end: ByteIndex(45) }, kind: Standard } })

Expected behavior The error should at least be human-readable, at best give a hint on what to fix.