guregu / null

reasonable handling of nullable values
BSD 2-Clause "Simplified" License
1.84k stars 238 forks source link

undefined: sql.NullTime #59

Closed jpsmith1981 closed 3 years ago

jpsmith1981 commented 4 years ago

Does this library support golang 1.13.

We just upgraded our application to 1.13 and now are getting:

2020/08/24 00:12:38 Failed to build app: building app with command [go build -o /tmp/staging/usr/local/bin/start bitbucket.org/x1x1x1x1/y1y1y1/z1z1z1], env [PATH=/go/bin:/usr/local/go/bin:/builder/google-cloud-sdk/bin/:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin HOSTNAME=cb5c804c1756 HOME=/builder/home BUILDER_OUTPUT=/builder/outputs DEBIAN_FRONTEND=noninteractive GOROOT=/usr/local/go/ GOPATH=/go GOPATH=/tmp/staging/srv/gopath]: err=exit status 2, out=# github.com/guregu/null
srv/gopath/src/github.com/guregu/null/time.go:15:2: undefined: sql.NullTime

It looks like there were some changes to the SQL libraries in the new versions of go lang. Is there something we need to support the changes in 1.13

guregu commented 4 years ago

The current version of this library (v4) uses sql.NullTime which was added in Go 1.13 (ref). It should work with Go 1.13, are you sure there's not something wrong with your build environment?

You can use v3 if you need to support older versions of Go: import "gopkg.in/guregu/null.v3"