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

May be a case where hackage-security client uses 100% CPU and does not terminate #192

Open
mgsloan opened this issue Nov 14, 2017 · 4 comments

Comments

@mgsloan
Copy link

mgsloan commented Nov 14, 2017

See this stack issue: commercialhaskell/stack#3572

Assuming it's from a relatively recent version of stack, this is likely a bug in hackage-security.

@hvr
Copy link
Member

hvr commented Nov 14, 2017

Is there any chance to get a reasonably reliable repro-case? It's going to be quite difficult to track this down without additional information; and from the logging output in that ticket it's not clear to me which entry-point into hackage-security got stuck.

@alexanderkjeldaas
Copy link

how can I give useful log-output. I have this as a docker image so it's fairly easy to repro.

@hvr
Copy link
Member

hvr commented Nov 14, 2017

@alexanderkjeldaas That sounds promising! I'm not familiar with Stack, but I'd try turning up verbosity to the max in the hopes to get as much log-messages from hackage-security (as well as from the transport layer; if there doesn't appear to be enough logging for the transport layer, tcpdump would be worth a try) emitted as possible. If this also doesn't give enough hints, good old printf-style debugging might be in order...; but let's cross that bridge when we come to it...

@mgsloan
Copy link
Author

mgsloan commented Nov 15, 2017

I do not think that verbosity is likely to help much. Stack does very little between Updating package index ... and running code from hackage security. In all codepaths after hackage security returns, there are further messages.

However, it may be helpful to know that -v --cabal-verbose is the max verbosity (verbose stack logs + verbose cabal logs). This will not have an effect on the output of hackage security, because it doesn't seem to have verbosity settings. The function we are passing in for it to use for output (7th argument of withRepossitory), is a function that always outputs regardless of verbosity level.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants