Add immediate caller info to the Error constructor (probably default arg?) #724
Labels
No labels
Affects/CppNix
Affects/Nightly
Affects/Only nightly
Affects/Stable
Area/build-packaging
Area/cli
Area/evaluator
Area/fetching
Area/flakes
Area/language
Area/lix ci
Area/nix-eval-jobs
Area/profiles
Area/protocol
Area/releng
Area/remote-builds
Area/repl
Area/repl/debugger
Area/store
bug
Context
contributors
Context
drive-by
Context
maintainers
Context
RFD
crash 💥
Cross Compilation
devx
docs
Downstream Dependents
E/easy
E/hard
E/help wanted
E/reproducible
E/requires rearchitecture
imported
Language/Bash
Language/C++
Language/NixLang
Language/Python
Language/Rust
Needs Langver
OS/Linux
OS/macOS
performance
regression
release-blocker
stability
Status
blocked
Status
invalid
Status
postponed
Status
wontfix
testing
testing/flakey
Topic/Large Scale Installations
ux
No milestone
No project
No assignees
3 participants
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference: lix-project/lix#724
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
We have been dealing with nasty problems on HEAD where we don't have exact info as to where the errors are coming from since multiple sites share the same message. Enough of this, let's do
#[track_caller]
equivalent things.I don't recall the exact way, but you can get the info: it's probably best done by a defaulted argument that constructs a source location class that gets it statically.
aha: https://en.cppreference.com/w/cpp/utility/source_location
our plan was to do both that and extend the caller info at every TRY_AWAIT that propagates an exception outward. it's not a complete stack reconstruction, but it's probably close enough?
This issue was mentioned on Gerrit on the following CLs:
This is probably sufficiently accomplished by
cl/2947
, but maybe there is some further stuff we could do.not sure? we only track on awaits, and the actual caller of the error ctor isn't even in that trace
ah okay, yes, we probably should yoink this still, in that case.