Skip to content
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

Missing line numbers for anonymous functions in stacktrace #1452

Closed
joepie91 opened this issue Jul 9, 2017 · 2 comments
Closed

Missing line numbers for anonymous functions in stacktrace #1452

joepie91 opened this issue Jul 9, 2017 · 2 comments
Assignees
Labels
error-messages Confusing messages and better diagnostics stale

Comments

@joepie91
Copy link

joepie91 commented Jul 9, 2017

There's a bug somewhere in my NixOps deployment specification, and this produced the following stacktrace:

$ nixops info -d osmium-testing --show-trace
error: while evaluating the attribute ‘config.deployment’ at /nix/store/j1hb3za87443jwkf22nz5yyjy3mg935r-nixos-17.03.1482.1b57bf274a/nixos/lib/attrsets.nix:199:44:
while evaluating anonymous function at /nix/store/j1hb3za87443jwkf22nz5yyjy3mg935r-nixos-17.03.1482.1b57bf274a/nixos/lib/options.nix:117:41, called from /nix/store/j1hb3za87443jwkf22nz5yyjy3mg935r-nixos-17.03.1482.1b57bf274a/nixos/lib/attrsets.nix:199:52:
while evaluating ‘scrubOptionValue’ at /nix/store/j1hb3za87443jwkf22nz5yyjy3mg935r-nixos-17.03.1482.1b57bf274a/nixos/lib/options.nix:113:22, called from /nix/store/j1hb3za87443jwkf22nz5yyjy3mg935r-nixos-17.03.1482.1b57bf274a/nixos/lib/options.nix:117:44:
while evaluating ‘isDerivation’ at /nix/store/j1hb3za87443jwkf22nz5yyjy3mg935r-nixos-17.03.1482.1b57bf274a/nixos/lib/attrsets.nix:295:18, called from /nix/store/j1hb3za87443jwkf22nz5yyjy3mg935r-nixos-17.03.1482.1b57bf274a/nixos/lib/options.nix:114:8:
while evaluating the attribute ‘config’ at /nix/var/nix/profiles/per-user/root/channels/nixos/nixpkgs/nixos/lib/eval-config.nix:53:5:
while evaluating the attribute ‘config’ at /nix/var/nix/profiles/per-user/root/channels/nixos/nixpkgs/lib/modules.nix:87:25:
while evaluating ‘yieldConfig’ at /nix/var/nix/profiles/per-user/root/channels/nixos/nixpkgs/lib/modules.nix:74:29, called from /nix/var/nix/profiles/per-user/root/channels/nixos/nixpkgs/lib/modules.nix:73:16:
while evaluating ‘mergeModules’ at /nix/var/nix/profiles/per-user/root/channels/nixos/nixpkgs/lib/modules.nix:178:26, called from /nix/var/nix/profiles/per-user/root/channels/nixos/nixpkgs/lib/modules.nix:64:17:
while evaluating ‘mergeModules'’ at /nix/var/nix/profiles/per-user/root/channels/nixos/nixpkgs/lib/modules.nix:182:36, called from /nix/var/nix/profiles/per-user/root/channels/nixos/nixpkgs/lib/modules.nix:179:5:
while evaluating ‘concatMap’ at /nix/var/nix/profiles/per-user/root/channels/nixos/nixpkgs/lib/lists.nix:79:18, called from /nix/var/nix/profiles/per-user/root/channels/nixos/nixpkgs/lib/modules.nix:218:9:
while evaluating ‘reverseList’ at /nix/var/nix/profiles/per-user/root/channels/nixos/nixpkgs/lib/lists.nix:256:17, called from /nix/var/nix/profiles/per-user/root/channels/nixos/nixpkgs/lib/modules.nix:64:38:
while evaluating ‘closeModules’ at /nix/var/nix/profiles/per-user/root/channels/nixos/nixpkgs/lib/modules.nix:91:27, called from /nix/var/nix/profiles/per-user/root/channels/nixos/nixpkgs/lib/modules.nix:59:16:
while evaluating anonymous function at /nix/var/nix/profiles/per-user/root/channels/nixos/nixpkgs/lib/lists.nix:71:28, called from undefined position:
while evaluating anonymous function at /nix/var/nix/profiles/per-user/root/channels/nixos/nixpkgs/lib/modules.nix:93:49, called from /nix/var/nix/profiles/per-user/root/channels/nixos/nixpkgs/lib/lists.nix:71:31:
while evaluating the module argument `pkgs' in ":anon-2:anon-1:anon-1":
infinite recursion encountered, at /nix/var/nix/profiles/per-user/root/channels/nixos/nixpkgs/lib/modules.nix:151:28
warning: evaluation of the deployment specification failed; status info may be incorrect

Unfortunately, it appears the issue lies with the :anon-2:anon-1:anon-1 section (as there are no other local paths in the stacktrace), and no line number is listed for anonymous functions.

This is a UX problem that should probably be fixed; right now, I have no idea where to look for the error, and I don't immediately see a reason why anonymous functions couldn't include line numbers as well.

@shlevy shlevy added the backlog label Apr 1, 2018
@domenkozar domenkozar added error-messages Confusing messages and better diagnostics and removed backlog labels Apr 16, 2020
@stale
Copy link

stale bot commented Feb 16, 2021

I marked this as stale due to inactivity. → More info

@stale stale bot added the stale label Feb 16, 2021
@domenkozar
Copy link
Member

I'm closing this as it was most probably fixed by adding a pos to a number of function calls.

Since it's not possible to reproduce the issue we can't ever be sure :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
error-messages Confusing messages and better diagnostics stale
Projects
None yet
Development

No branches or pull requests

4 participants