-
-
Notifications
You must be signed in to change notification settings - Fork 1.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Pass positions when evaluating #9555
Conversation
Could you turn the example into a test case? |
14803bb
to
16b6de1
Compare
16b6de1
to
44ee3c0
Compare
Done! (I finished this at the end of the day and didn't have time to write tests.) |
This includes position information in more places, making debugging easier. Before: ``` $ nix-instantiate --show-trace --eval tests/functional/lang/eval-fail-using-set-as-attr-name.nix error: … while evaluating an attribute name at «none»:0: (source not available) error: value is a set while a string was expected ``` After: ``` error: … while evaluating an attribute name at /pwd/lang/eval-fail-using-set-as-attr-name.nix:5:10: 4| in 5| attr.${key} | ^ 6| error: value is a set while a string was expected ```
44ee3c0
to
0b80935
Compare
|
||
at «none»:0: (source not available) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
at «none»:0: (source not available) |
It didn't do that anymore since 2.19.
You may set _NIX_DEVELOPER_SHOW_UNKNOWN_LOCATIONS=1
to show the missing positions once more.
Awesome, thanks! |
Pass positions when evaluating (cherry picked from commit c8458bd) Change-Id: I1b4a5d58973be6264ffdb23b4492da200fdb71be
Motivation
This includes position information in more places, making debugging easier. This removes
«none»:0: (source not available)
from error messages in many cases.Context
Final fix for #561 (comment).
Before:
After:
Before:
After:
Before:
After:
Priorities
Add 👍 to pull requests you find important.