mirror of
https://github.com/privatevoid-net/nix-super.git
synced 2024-12-03 19:06:16 +02:00
83bb494a30
This extends the `error: cannot coerce a TYPE to a string` message to print the value that could not be coerced. This helps with debugging by making it easier to track down where the value is being produced from, especially in errors with deep or unhelpful stack traces.
24 lines
636 B
Markdown
24 lines
636 B
Markdown
---
|
|
synopsis: Coercion errors include the failing value
|
|
issues: #561
|
|
prs: #9754
|
|
---
|
|
|
|
The `error: cannot coerce a <TYPE> to a string` message now includes the value
|
|
which caused the error.
|
|
|
|
Before:
|
|
|
|
```
|
|
error: cannot coerce a set to a string
|
|
```
|
|
|
|
After:
|
|
|
|
```
|
|
error: cannot coerce a set to a string: { aesSupport = «thunk»;
|
|
avx2Support = «thunk»; avx512Support = «thunk»; avxSupport = «thunk»;
|
|
canExecute = «thunk»; config = «thunk»; darwinArch = «thunk»; darwinMinVersion
|
|
= «thunk»; darwinMinVersionVariable = «thunk»; darwinPlatform = «thunk»; «84
|
|
attributes elided»}
|
|
```
|