golang-evdev icon indicating copy to clipboard operation
golang-evdev copied to clipboard

Log errors instead of failing in some cases

Open maitredede opened this issue 6 years ago • 1 comments

In some cases, a ioctl error should not block the full function since it is an normal behavior (for example, something not supported by the device).

maitredede avatar Oct 28 '19 19:10 maitredede

Libraries in packages such as this one should never log themselves, as that clashes with the logging in place of the application using them. If you want to augment the error to give more context (which totally makes sense), use fmt.Errorf() or wrap the error as described here

zonque avatar Mar 30 '20 12:03 zonque