-
Notifications
You must be signed in to change notification settings - Fork 843
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
Show resolver being used when stack ghci
is invoked outside of a project directory
#3651
Comments
Makes sense! It should also probably say something like "Using global project ..." which would at least make it clear where it was getting the config. If you update to 1.6.1 and have a normal global project, you'll at least get:
|
@mgsloan I am getting the warning you quoted above. How do I get rid of it? I don't want to use a |
@raxod502 Hmm, why does getting the warning matter? Perhaps I should turn it into an |
@mgsloan If I get a warning, then it means I need to fix something. If there's nothing wrong, then what is there to "warn" about? But perhaps using |
I guess it's a difference of semantics. A warning does not mean there is something you need to fix - an error does. For example, an identifier aliasing or unused identifier warning from GHC does not mean there is something that needs to be fixed. It just so happens that most GHC warnings are resolvable while retaining semantics. In this case there is no direct way to make the warning go away. I would be fine with making it an "Note: " instead of "Warning: ", I can understand how this would be confusing. |
The primary reason the message was confusing to me was that it says |
This is fantastic! Much clearer, thanks so much. |
Yes, thank you! It's a bit embarrassing when I'm trying to show off a fancy tool and it's printing warnings while nothing is wrong, it makes the experience look unpolished. |
By the way, is there any command-line option or other configuration change that would prevent the message from being printed at all? |
There isn't a good way to silence these hints / warnings without also silencing other things. Could be added, but not sure what to call it. You could do |
Now that I have some more experience with Haskell, I think that what I should have been doing was
rather than
because all I wanted was a plain GHCI in the global project. It's not entirely clear to me what the difference between the two commands is, but I can understand if one produces a warning when used in this way, if indeed I should have been using a different command in the first place. Perhaps this information could be added to the hint, unless I'm totally off the mark here. |
If your global project has no packages (and it probably shouldn't), then If I run
I don't think the
Which doesn't do anything. So yeah, they're very similar. |
Is there a way to fire up |
@EdmundsEcho There's sharing for packages that are included in the stackage snapshot, so you should only need to build Perhaps that could be streamlined by eagerly populating the package DBs with everything that's precompiled, but it doesn't seem worth it. Every build of a snapshot package would need to check every snapshot DB to see if the package can also be added to it.. Would slow things down quite a bit for a fairly unusual usecase. |
I am going to close this issue as, with Stack 2.15.5, the snapshot is reported. |
When I run
stack ghci
outside of a project directory I get output like:It would be very helpful to display the resolver being used in this scenario.
The text was updated successfully, but these errors were encountered: