-
Notifications
You must be signed in to change notification settings - Fork 1
Refactor context handling #84
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
Conversation
6c82d02 to
0bc7923
Compare
839eaa4 to
bea092c
Compare
bf6896d to
0d269e8
Compare
Stop using context.Background() and use a root context that's got signal.NotifyContext() on it. This allows control-C to interrupt everything. Use the main context for the MCP handler as well
0d269e8 to
6d3bc32
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Left a comment about a couple other places where we should use the new readString function, so that reading from stdin can be canceled via ctrl-c. Might want to move that readString function into the util package or something, given that we'll probably end up using it in a bunch of different places.
Other than that, this LGTM!
b6ced91 to
cc143ed
Compare
cc143ed to
9a82a02
Compare
Stop using context.Background() and use a root context that's got signal.NotifyContext() on it. This allows control-C to interrupt everything.