Open connorkuehl opened 1 year ago
I don't think it would have to be breaking, the non-ctx variants, and explicit timeout arg variants, could all be written backwards compatibly in terms of the APIs that have a ctx arg. Some of the golang core APIs did this, they have a ...WithCtx(ctx, ..)
or just ...Ctx(ctx, ...)
version.
Client code would benefit a lot from context cancellation support. I suspect we could update the code generator to add context.Context parameters that many Go programmers might already be used to and thread those through to Libvirt.getResponse.
Perhaps this breaking change is the line we could cross to cut a v1 module of go-libvirt to avoid breaking client code in a confusing way.