I recently started using modules in Go, but I frequently encounter issues where everything works fine on one machine, but a checksum mismatch is encountered when building the co
You need to delete your package from the go.sum file. If you run from terminal mode, using CI/CD or Dockerfile you can use that sh command:
sed '/^github.com\/ericlagergren\/decimal@/d' ./go.sum > temp.txt && mv temp.txt go.sum
Which does:
P.S.: go mod tidy
- only removes unused packages and add new versions. But it doesn`t delete olders.