You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the bug
Building a project with Bazel on Linux fails with
external/com_github_jackc_pgx_v5/internal/nbconn/nbconn.go:379:12: c.realNonblockingWrite undefined (type *NetConn has no field or method realNonblockingWrite)
external/com_github_jackc_pgx_v5/internal/nbconn/nbconn.go:412:12: c.realNonblockingRead undefined (type *NetConn has no field or method realNonblockingRead)
Steps to reproduce
Create a go project that uses pgx v5.
Compile the project with bazel: bazel build ./...
Expected behavior
The build succeeds.
Actual behavior
ERROR: /home/tag/.cache/bazel/_bazel_tag/e379d280809b10b9e36a69cb312affe2/external/com_github_jackc_pgx_v5/internal/nbconn/BUILD.bazel:3:11: GoCompilePkg external/com_github_jackc_pgx_v5/internal/nbconn/nbconn.a failed: (Exit 1): builder failed: error executing command bazel-out/k8-opt-exec-2B5CBBC6/bin/external/go_sdk/builder_reset/builder compilepkg -sdk external/go_sdk -installsuffix linux_amd64 -src external/com_github_jackc_pgx_v5/internal/nbconn/bufferqueue.go ... (remaining 26 arguments skipped)
Use --sandbox_debug to see verbose messages from the sandbox and retain the sandbox build root for debugging
external/com_github_jackc_pgx_v5/internal/nbconn/nbconn.go:379:12: c.realNonblockingWrite undefined (type *NetConn has no field or method realNonblockingWrite)
external/com_github_jackc_pgx_v5/internal/nbconn/nbconn.go:412:12: c.realNonblockingRead undefined (type *NetConn has no field or method realNonblockingRead)
compilepkg: error running subcommand external/go_sdk/pkg/tool/linux_amd64/compile: exit status 2
Version
Go: $ go version -> go version go1.19.5 linux/amd64
PostgreSQL: $ psql --no-psqlrc --tuples-only -c 'select version()' -> psql: error: connection to server on socket "/var/run/postgresql/.s.PGSQL.5432" failed: FATAL: role "tag" does not exist
I just ran into this problem in a project that uses bazel once I upgraded from v4 to v5. It compiles fine with go build so this is a bazel bug. @jackc, you should feel free to close this issue if you like.
Describe the bug
Building a project with Bazel on Linux fails with
Steps to reproduce
bazel build ./...
Expected behavior
The build succeeds.
Actual behavior
Version
$ go version
->go version go1.19.5 linux/amd64
$ psql --no-psqlrc --tuples-only -c 'select version()'
->psql: error: connection to server on socket "/var/run/postgresql/.s.PGSQL.5432" failed: FATAL: role "tag" does not exist
$ grep 'github.com/jackc/pgx/v[0-9]' go.mod
->github.com/jackc/pgx/v5 v5.3.0
Additional context
The project builds fine with v5.2.0. This is probably related to cf78472
The text was updated successfully, but these errors were encountered: