Releases: tomarrell/wrapcheck
Compile with Go v1.21
Update dependencies, support Go v1.22
What's Changed
Support for Go v1.22.
- deps: upgrade golang.org/x/tools by @rledisez & @tomarrell in #48
Full Changelog: v2.8.1...v2.8.2
Bump dependency version
Bumps golang.org/x/text from 0.3.7 to 0.3.8.
Ignore `errors.Join()` sig by default
The new errors.Join()
function was added in Go 1.20, it should be ignored by default.
More info in the Go 1.20 release notes: https://tip.golang.org/doc/go1.20#errors
Check interfaces against ignorePackageGlobs
This release introduces checking of the interface's package against the configured ignorePackageGlobs values.
Previously, only functions called directly from other packages had their packages checked against this option, however this behaviour was unintuitive. This change checks the interface package as well, ignoring interfaces which originate from a package matching a glob pattern.
Closes #34
Update Dependencies
Closes #30, updates x/tools
to latest.
Update Dependencies
This release fixes an issue when running wrapcheck over a Go v1.18 codebase due to an older version of a dependency.
Config to ignore interfaces
This release adds the config parameter ignoreInterfaceRegexps
, which provides the ability to specify regex patterns which will ignore calls through an interface with a matching name.
For example:
ignoreInterfaceRegexps:
- [dD]ecoder
The above configuration will cause errors returned by methods called on an interface named decoder
or Decoder
to skip wrapcheck analysis.
Many thanks to @guillaumeio for the contribution!
Improved compilation of `ignoreSigRegexp`
This releases front-loads the compilation of regexps provided via the config file, enabling immediate error reporting.
It also removes the os.Exit(1)
upon failing to compile the regexps, to play nicer with golangci-lint.
Ignore signature by Regex
This release adds the ability to configure wrapcheck to ignore signatures using regex matching using the ignoreSigRegexps
config value. Example configuration is below.
# An array of strings which specify regular expressions of signatures to ignore.
# This is similar to the ignoreSigs configuration above, but gives slightly more
# flexibility.
ignoreSigRegexps:
- \.New.*Error\(