How to Install and Uninstall golang-github-hashicorp-errwrap-dev Package on Ubuntu 21.10 (Impish Indri)

Last updated: December 27,2024

1. Install "golang-github-hashicorp-errwrap-dev" package

This guide let you learn how to install golang-github-hashicorp-errwrap-dev on Ubuntu 21.10 (Impish Indri)

$ sudo apt update $ sudo apt install golang-github-hashicorp-errwrap-dev

2. Uninstall "golang-github-hashicorp-errwrap-dev" package

Here is a brief guide to show you how to uninstall golang-github-hashicorp-errwrap-dev on Ubuntu 21.10 (Impish Indri):

$ sudo apt remove golang-github-hashicorp-errwrap-dev $ sudo apt autoclean && sudo apt autoremove

3. Information about the golang-github-hashicorp-errwrap-dev package on Ubuntu 21.10 (Impish Indri)

Package: golang-github-hashicorp-errwrap-dev
Architecture: all
Version: 1.1.0-1
Multi-Arch: foreign
Priority: extra
Section: universe/devel
Source: golang-github-hashicorp-errwrap
Origin: Ubuntu
Maintainer: Ubuntu Developers
Original-Maintainer: Debian Go Packaging Team
Bugs: https://bugs.launchpad.net/ubuntu/+filebug
Installed-Size: 24
Filename: pool/universe/g/golang-github-hashicorp-errwrap/golang-github-hashicorp-errwrap-dev_1.1.0-1_all.deb
Size: 6212
MD5sum: 4d9e15d675a103ce106c6ed3fefe708a
SHA1: 38fffe90963a1e8ce659d81dca41ca6ec468ec4f
SHA256: 3f0b989036ca0664755e76c165095404b024c1deb2593a831b335e287c69ecd7
SHA512: 3019599a8c850437a1bb26522264bb859503237005ec6ffc8cbdca88a6ffc3693cade2f1a6d1da21ee8e9ab4bceb511aa7f26c6fdff6d06908cf75244cb0c3cd
Homepage: https://github.com/hashicorp/errwrap
Description-en: Errwrap is a Go (golang) library for wrapping and querying errors
errwrap is a package for Go that formalizes the pattern of wrapping errors and
checking if an error contains another error.
.
There is a common pattern in Go of taking a returned error value and then
wrapping it (such as with fmt.Errorf) before returning it. The problem with
this pattern is that you completely lose the original error structure.
.
Arguably the correct approach is that you should make a custom structure
implementing the error interface, and have the original error as a field on
that structure, such as this example. This is a good approach, but you have to
know the entire chain of possible rewrapping that happens, when you might just
care about one.
.
errwrap formalizes this pattern (it doesn't matter what approach you use above)
by giving a single interface for wrapping errors, checking if a specific error
is wrapped, and extracting that error.
.
This package contains the source.
Description-md5: 8f9ccf8319716d5c9b3fe6b07ffaa505