pingcap / failpoint

An implementation of failpoints for Golang.
Apache License 2.0
817 stars 63 forks source link

failpoint.Disable should be idempotent #76

Closed tisonkun closed 2 years ago

tisonkun commented 2 years ago

This closes #75.

It will change the interface of failpoint.Disable but not failpoints.Disable and thus almost usage should be fine.

failpoint.Disable now never return an error because it always succeeds now. If we want to be backward compatible on compilation (but we don't even do a semver release), we can keep the interface and return nil always.

Signed-off-by: tison wander4096@gmail.com

tisonkun commented 2 years ago

cc @kennytm @lonng