[Nix#10105] repl :log does not support derivation paths #51

Closed
opened 2024-03-16 06:44:39 +00:00 by lix-bot · 1 comment
Member

Upstream-Issue: NixOS/nix#10105

Describe the bug

nix-repl> :log /nix/store/fiip84zv229vagk4i290f74jj383m2pf-vm-test-run-nixops-legacy-network.drv
error: expression does not evaluate to a derivation, so I can't build it

This is nonsensical in two ways, both of which should be fixed:

  • It already is a derivation; no need to really evaluate.
  • "I can't build it" doesn't make sense for :log. It seems that some method's error message wrongly assumes we're trying to build a derivation.

Steps To Reproduce

As above.

Expected behavior

It shows the log.

nix-env --version output

Additional context

Workaround: the "forbidden" import. Please don't use import like that.

nix-repl> :log import /nix/store/fiip84zv229vagk4i290f74jj383m2pf-vm-test-run-nixops-legacy-network.drv

Priorities

Add 👍 to issues you find important.

Upstream-Issue: https://git.lix.systems/NixOS/nix/issues/10105 **Describe the bug** ``` nix-repl> :log /nix/store/fiip84zv229vagk4i290f74jj383m2pf-vm-test-run-nixops-legacy-network.drv error: expression does not evaluate to a derivation, so I can't build it ``` This is nonsensical in two ways, both of which should be fixed: - It already is a derivation; no need to really evaluate. - "I can't build it" doesn't make sense for `:log`. It seems that some method's error message wrongly assumes we're trying to build a derivation. **Steps To Reproduce** As above. **Expected behavior** It shows the log. **`nix-env --version` output** **Additional context** Workaround: the "forbidden" `import`. Please don't use `import` like that. ``` nix-repl> :log import /nix/store/fiip84zv229vagk4i290f74jj383m2pf-vm-test-run-nixops-legacy-network.drv ``` **Priorities** Add :+1: to [issues you find important](https://github.com/NixOS/nix/issues?q=is%3Aissue+is%3Aopen+sort%3Areactions-%2B1-desc).
lix-bot added the
bug
imported
labels 2024-03-16 06:44:39 +00:00
jade added the
E/easy
E/help wanted
labels 2024-03-18 16:27:03 +00:00
jade added the
Area/repl
label 2024-05-30 07:13:14 +00:00
goldstein self-assigned this 2024-08-05 13:29:15 +00:00
goldstein removed their assignment 2024-08-05 13:29:18 +00:00
goldstein self-assigned this 2024-08-05 13:29:24 +00:00
Author
Member

This issue was mentioned on Gerrit on the following CLs:

  • commit message in cl/1716 ("src/libcmd/repl.cc: allow :log /path/to/store.drv")
<!-- GERRIT_LINKBOT: {"cls": [{"backlink": "https://gerrit.lix.systems/c/lix/+/1716", "number": 1716, "kind": "commit message"}], "cl_meta": {"1716": {"change_title": "src/libcmd/repl.cc: allow :log /path/to/store.drv"}}} --> This issue was mentioned on Gerrit on the following CLs: * commit message in [cl/1716](https://gerrit.lix.systems/c/lix/+/1716) ("src/libcmd/repl.cc: allow :log /path/to/store.drv")
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference: lix-project/lix#51
No description provided.