Unwanted assertion "cannot be set to both the name
and the command
attributes"
#312
Labels
bug
Something isn't working
name
and the command
attributes"
#312
Hey,
is this assertion really correct or needed?
How to reproduce
Because I have such a case:
First this results in error:
But if I did
name = "my-ghci"
it would work, because the commandghci
is provided by the includedpackagesFrom = [ config.devShells.haskell ]
. So the assertion really bites me.Alternatives tried
I've tried combinations:
doesn't work because
package "ghci" not found
. I don't have direct access to the package, because I don't have a reference to it, it's included in thehaskell
shell created by a library function.Specifying only of
command
/name
fails with either:or
Finally, naming the command differently works like described above.
Why do I care?
because id like the command to appear in the nice menu.
Summary and realization
OK. I realized the problem. In my case the
ghci
command would overwrite theghci
command that's already in scope.Ill close this issue as dumb. Open a new feature request for displaying in menu commands originating from
packagesFrom
(this ties to issue #311). Refer to here to show how naive solution fails.The text was updated successfully, but these errors were encountered: