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

Resolve with parent context #99

Open
anisse opened this issue Mar 25, 2024 · 0 comments
Open

Resolve with parent context #99

anisse opened this issue Mar 25, 2024 · 0 comments

Comments

@anisse
Copy link

anisse commented Mar 25, 2024

To have proper cancellation, it would help to do all name resolution using the net.Resolver.LookupIP, which takes a context. It's already in use since version 0.4.0, but it uses context.Background as a base, not the context passed to RunWithContext. It would remove surprises like those in #64.

It would be a behaviour change, but not a very surprising one, and IMHO much less annoying than adding other APIs like ResolveWithContext and RunWithContextAndResolveWithContext.

Would you be open to such a PR?

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

1 participant