Skip to content

Conversation

@tamird
Copy link
Contributor

@tamird tamird commented Dec 9, 2025

  • dockerutil: improve error messages
    Currently these routines emit anemic errors on failure such as

    ==================== Test output for //test/image:image_test:
    2026/01/07 08:52:20 error running "docker version": exit status 1
    ==========================================================
    

    which is hardly actionable. Separate stdout and stderr for better error
    reporting and simplify while I'm here.

  • packetdrill: check that docker is usable
    Currently we're seeing infinite retry loops on docker network create
    which fail with Error response from daemon: client version 1.52 is too new. Maximum supported API version is 1.41. This should prevent that,
    though the underlying version mismatch still needs to be investigated.

  • checkescape: improve error output
    The output now includes stderr on failure e.g.:

    checkescape: tools/checkescape/test2/test2.go:98:6: stack: possible split on function entry (2 omitted) → (possible, error running "external/rules_go++go_sdk+main___download_0/bin/go tool objdump bazel-out/k8-fastbuild-ST-04c87098fb12/bin/tools/checkescape/test2/test2.a": exit status 2 (go: no such tool "objdump")) (GOOARCH=amd64, GOOS=linux)
    

    Simplify various bits of the implementation while I'm here:

    • Use a set of strings rather than a list to avoid some O(n) operations.
    • Use CommandContext to ensure proper cleanup.
    • Remove stderr pipe and goroutine by setting Stderr to a
      bytes.Buffer.
    • Use bufio.Scanner instead of manually calling
      (*bufio.Reader).ReadString and handling errors.
    • Remove NextLine loop label.
  • go_stateify: plumb go binary to goimports
    This avoids go_stateify relying on go being available outside of the
    bazel sandbox.

  • Reduce Go version duplication

    • Use go_sdk.from_file instead of repeating the version encoded in
      go.mod in MODULE.bazel.
    • Remove images/gpu/cuda-tests-12-8/install_go.sh; golang is already
      installed via apt and the version is immaterial.
  • bazel: update dependencies

  • Update Go to 1.25.5
    Add a workaround to allow objdump to be lazily compiled in the manner
    introduced in https://go.dev/issue/71867 when invoked under bazel in
    checkescape.

@tamird
Copy link
Contributor Author

tamird commented Dec 9, 2025

Notably 1.25 has synctest.

@tamird
Copy link
Contributor Author

tamird commented Dec 25, 2025

@avagin could you please have a look?

copybara-service bot pushed a commit that referenced this pull request Dec 27, 2025
FUTURE_COPYBARA_INTEGRATE_REVIEW=#12365 from tamird:update-go bae2687
PiperOrigin-RevId: 849319588
copybara-service bot pushed a commit that referenced this pull request Dec 27, 2025
FUTURE_COPYBARA_INTEGRATE_REVIEW=#12365 from tamird:update-go bae2687
PiperOrigin-RevId: 849319588
copybara-service bot pushed a commit that referenced this pull request Dec 27, 2025
FUTURE_COPYBARA_INTEGRATE_REVIEW=#12365 from tamird:update-go bae2687
PiperOrigin-RevId: 849319588
copybara-service bot pushed a commit that referenced this pull request Dec 27, 2025
FUTURE_COPYBARA_INTEGRATE_REVIEW=#12365 from tamird:update-go bae2687
PiperOrigin-RevId: 849319588
copybara-service bot pushed a commit that referenced this pull request Dec 29, 2025
FUTURE_COPYBARA_INTEGRATE_REVIEW=#12365 from tamird:update-go bae2687
PiperOrigin-RevId: 849319588
copybara-service bot pushed a commit that referenced this pull request Dec 29, 2025
FUTURE_COPYBARA_INTEGRATE_REVIEW=#12365 from tamird:update-go bae2687
PiperOrigin-RevId: 849319588
copybara-service bot pushed a commit that referenced this pull request Dec 29, 2025
FUTURE_COPYBARA_INTEGRATE_REVIEW=#12365 from tamird:update-go bae2687
PiperOrigin-RevId: 849319588
@tamird
Copy link
Contributor Author

tamird commented Jan 2, 2026

@avagin any clues on what's busted here? Looks like it's an internal check.

@avagin
Copy link
Collaborator

avagin commented Jan 2, 2026

@avagin any clues on what's busted here? Looks like it's an internal check.

buildkite/pipeline isn't happy:
#12413

https://buildkite.com/gvisor/pipeline/builds/39348/steps/canvas

@tamird
Copy link
Contributor Author

tamird commented Jan 2, 2026

Thanks. I'm not sure what the cause is so I added another commit. Is it possible to get a dry buildkite run?

copybara-service bot pushed a commit that referenced this pull request Jan 3, 2026
FUTURE_COPYBARA_INTEGRATE_REVIEW=#12365 from tamird:update-go aa1ff35
PiperOrigin-RevId: 849319588
copybara-service bot pushed a commit that referenced this pull request Jan 3, 2026
FUTURE_COPYBARA_INTEGRATE_REVIEW=#12365 from tamird:update-go aa1ff35
PiperOrigin-RevId: 849319588
copybara-service bot pushed a commit that referenced this pull request Jan 3, 2026
FUTURE_COPYBARA_INTEGRATE_REVIEW=#12365 from tamird:update-go aa1ff35
PiperOrigin-RevId: 849319588
copybara-service bot pushed a commit that referenced this pull request Jan 3, 2026
FUTURE_COPYBARA_INTEGRATE_REVIEW=#12365 from tamird:update-go aa1b5ee
PiperOrigin-RevId: 849319588
copybara-service bot pushed a commit that referenced this pull request Jan 3, 2026
FUTURE_COPYBARA_INTEGRATE_REVIEW=#12365 from tamird:update-go aa1b5ee
PiperOrigin-RevId: 849319588
copybara-service bot pushed a commit that referenced this pull request Jan 3, 2026
FUTURE_COPYBARA_INTEGRATE_REVIEW=#12365 from tamird:update-go aa1b5ee
PiperOrigin-RevId: 849319588
@tamird tamird force-pushed the update-go branch 7 times, most recently from fb7c725 to 42841ed Compare January 3, 2026 21:06
@tamird
Copy link
Contributor Author

tamird commented Jan 3, 2026

@avagin this should be ready for another look, in case you have to do something on your side to trigger copybara.

@tamird tamird force-pushed the update-go branch 3 times, most recently from 1724dcf to 6c7f640 Compare January 4, 2026 11:42
@tamird
Copy link
Contributor Author

tamird commented Jan 5, 2026

@avagin is this failure buildkite again? I don't see it in #12413.

copybara-service bot pushed a commit that referenced this pull request Jan 5, 2026
- **checkescape: improve error output**
  The output now includes stderr on failure e.g.:
  ```
  checkescape: tools/checkescape/test2/test2.go:98:6: stack: possible split on function entry (2 omitted) → (possible, error running "external/rules_go++go_sdk+main___download_0/bin/go tool objdump bazel-out/k8-fastbuild-ST-04c87098fb12/bin/tools/checkescape/test2/test2.a": exit status 2 (go: no such tool "objdump")) (GOOARCH=amd64, GOOS=linux)
  ```

  Simplify various bits of the implementation while I'm here:
  - Use a set of strings rather than a list to avoid some O(n) operations.
  - Use `CommandContext` to ensure proper cleanup.
  - Remove stderr pipe and goroutine by setting `Stderr` to a
    `bytes.Buffer`.
  - Use `bufio.Scanner` instead of manually calling
    `(*bufio.Reader).ReadString` and handling errors.
  - Remove `NextLine` loop label.
-  **go_stateify: plumb go binary to goimports**
    This avoids go_stateify relying on `go` being available outside of the
    bazel sandbox.
- **Update Go to 1.25.5**
  Reduce duplication of the version information in various places:
  - Use `go_sdk.from_file` instead of repeating the version encoded in
    `go.mod` in `MODULE.bazel`.
  - Remove `images/gpu/cuda-tests-12-8/install_go.sh`; golang is already
    installed via apt and the version is immaterial.

  Add a workaround to allow `objdump` to be lazily compiled in the manner
  introduced in https://go.dev/issue/71867 when invoked under bazel in
  checkescape.

FUTURE_COPYBARA_INTEGRATE_REVIEW=#12365 from tamird:update-go 6c7f640
PiperOrigin-RevId: 852335920
copybara-service bot pushed a commit that referenced this pull request Jan 5, 2026
- **checkescape: improve error output**
  The output now includes stderr on failure e.g.:
  ```
  checkescape: tools/checkescape/test2/test2.go:98:6: stack: possible split on function entry (2 omitted) → (possible, error running "external/rules_go++go_sdk+main___download_0/bin/go tool objdump bazel-out/k8-fastbuild-ST-04c87098fb12/bin/tools/checkescape/test2/test2.a": exit status 2 (go: no such tool "objdump")) (GOOARCH=amd64, GOOS=linux)
  ```

  Simplify various bits of the implementation while I'm here:
  - Use a set of strings rather than a list to avoid some O(n) operations.
  - Use `CommandContext` to ensure proper cleanup.
  - Remove stderr pipe and goroutine by setting `Stderr` to a
    `bytes.Buffer`.
  - Use `bufio.Scanner` instead of manually calling
    `(*bufio.Reader).ReadString` and handling errors.
  - Remove `NextLine` loop label.
-  **go_stateify: plumb go binary to goimports**
    This avoids go_stateify relying on `go` being available outside of the
    bazel sandbox.
- **Update Go to 1.25.5**
  Reduce duplication of the version information in various places:
  - Use `go_sdk.from_file` instead of repeating the version encoded in
    `go.mod` in `MODULE.bazel`.
  - Remove `images/gpu/cuda-tests-12-8/install_go.sh`; golang is already
    installed via apt and the version is immaterial.

  Add a workaround to allow `objdump` to be lazily compiled in the manner
  introduced in https://go.dev/issue/71867 when invoked under bazel in
  checkescape.

FUTURE_COPYBARA_INTEGRATE_REVIEW=#12365 from tamird:update-go 6c7f640
PiperOrigin-RevId: 852335920
@tamird tamird mentioned this pull request Jan 5, 2026
avagin pushed a commit that referenced this pull request Jan 6, 2026
- **checkescape: improve error output**
  The output now includes stderr on failure e.g.:
  ```
  checkescape: tools/checkescape/test2/test2.go:98:6: stack: possible split on function entry (2 omitted) → (possible, error running "external/rules_go++go_sdk+main___download_0/bin/go tool objdump bazel-out/k8-fastbuild-ST-04c87098fb12/bin/tools/checkescape/test2/test2.a": exit status 2 (go: no such tool "objdump")) (GOOARCH=amd64, GOOS=linux)
  ```

  Simplify various bits of the implementation while I'm here:
  - Use a set of strings rather than a list to avoid some O(n) operations.
  - Use `CommandContext` to ensure proper cleanup.
  - Remove stderr pipe and goroutine by setting `Stderr` to a
    `bytes.Buffer`.
  - Use `bufio.Scanner` instead of manually calling
    `(*bufio.Reader).ReadString` and handling errors.
  - Remove `NextLine` loop label.
-  **go_stateify: plumb go binary to goimports**
    This avoids go_stateify relying on `go` being available outside of the
    bazel sandbox.
- **Update Go to 1.25.5**
  Reduce duplication of the version information in various places:
  - Use `go_sdk.from_file` instead of repeating the version encoded in
    `go.mod` in `MODULE.bazel`.
  - Remove `images/gpu/cuda-tests-12-8/install_go.sh`; golang is already
    installed via apt and the version is immaterial.

  Add a workaround to allow `objdump` to be lazily compiled in the manner
  introduced in https://go.dev/issue/71867 when invoked under bazel in
  checkescape.

FUTURE_COPYBARA_INTEGRATE_REVIEW=#12365 from tamird:update-go 6c7f640
PiperOrigin-RevId: 852335920
avagin pushed a commit that referenced this pull request Jan 6, 2026
- **checkescape: improve error output**
  The output now includes stderr on failure e.g.:
  ```
  checkescape: tools/checkescape/test2/test2.go:98:6: stack: possible split on function entry (2 omitted) → (possible, error running "external/rules_go++go_sdk+main___download_0/bin/go tool objdump bazel-out/k8-fastbuild-ST-04c87098fb12/bin/tools/checkescape/test2/test2.a": exit status 2 (go: no such tool "objdump")) (GOOARCH=amd64, GOOS=linux)
  ```

  Simplify various bits of the implementation while I'm here:
  - Use a set of strings rather than a list to avoid some O(n) operations.
  - Use `CommandContext` to ensure proper cleanup.
  - Remove stderr pipe and goroutine by setting `Stderr` to a
    `bytes.Buffer`.
  - Use `bufio.Scanner` instead of manually calling
    `(*bufio.Reader).ReadString` and handling errors.
  - Remove `NextLine` loop label.
-  **go_stateify: plumb go binary to goimports**
    This avoids go_stateify relying on `go` being available outside of the
    bazel sandbox.
- **Update Go to 1.25.5**
  Reduce duplication of the version information in various places:
  - Use `go_sdk.from_file` instead of repeating the version encoded in
    `go.mod` in `MODULE.bazel`.
  - Remove `images/gpu/cuda-tests-12-8/install_go.sh`; golang is already
    installed via apt and the version is immaterial.

  Add a workaround to allow `objdump` to be lazily compiled in the manner
  introduced in https://go.dev/issue/71867 when invoked under bazel in
  checkescape.

FUTURE_COPYBARA_INTEGRATE_REVIEW=#12365 from tamird:update-go 6c7f640
PiperOrigin-RevId: 852335920
copybara-service bot pushed a commit that referenced this pull request Jan 6, 2026
- **checkescape: improve error output**
  The output now includes stderr on failure e.g.:
  ```
  checkescape: tools/checkescape/test2/test2.go:98:6: stack: possible split on function entry (2 omitted) → (possible, error running "external/rules_go++go_sdk+main___download_0/bin/go tool objdump bazel-out/k8-fastbuild-ST-04c87098fb12/bin/tools/checkescape/test2/test2.a": exit status 2 (go: no such tool "objdump")) (GOOARCH=amd64, GOOS=linux)
  ```

  Simplify various bits of the implementation while I'm here:
  - Use a set of strings rather than a list to avoid some O(n) operations.
  - Use `CommandContext` to ensure proper cleanup.
  - Remove stderr pipe and goroutine by setting `Stderr` to a
    `bytes.Buffer`.
  - Use `bufio.Scanner` instead of manually calling
    `(*bufio.Reader).ReadString` and handling errors.
  - Remove `NextLine` loop label.
-  **go_stateify: plumb go binary to goimports**
    This avoids go_stateify relying on `go` being available outside of the
    bazel sandbox.
- **Update Go to 1.25.5**
  Reduce duplication of the version information in various places:
  - Use `go_sdk.from_file` instead of repeating the version encoded in
    `go.mod` in `MODULE.bazel`.
  - Remove `images/gpu/cuda-tests-12-8/install_go.sh`; golang is already
    installed via apt and the version is immaterial.

  Add a workaround to allow `objdump` to be lazily compiled in the manner
  introduced in https://go.dev/issue/71867 when invoked under bazel in
  checkescape.

FUTURE_COPYBARA_INTEGRATE_REVIEW=#12365 from tamird:update-go 6c7f640
PiperOrigin-RevId: 852335920
copybara-service bot pushed a commit that referenced this pull request Jan 6, 2026
- **checkescape: improve error output**
  The output now includes stderr on failure e.g.:
  ```
  checkescape: tools/checkescape/test2/test2.go:98:6: stack: possible split on function entry (2 omitted) → (possible, error running "external/rules_go++go_sdk+main___download_0/bin/go tool objdump bazel-out/k8-fastbuild-ST-04c87098fb12/bin/tools/checkescape/test2/test2.a": exit status 2 (go: no such tool "objdump")) (GOOARCH=amd64, GOOS=linux)
  ```

  Simplify various bits of the implementation while I'm here:
  - Use a set of strings rather than a list to avoid some O(n) operations.
  - Use `CommandContext` to ensure proper cleanup.
  - Remove stderr pipe and goroutine by setting `Stderr` to a
    `bytes.Buffer`.
  - Use `bufio.Scanner` instead of manually calling
    `(*bufio.Reader).ReadString` and handling errors.
  - Remove `NextLine` loop label.
-  **go_stateify: plumb go binary to goimports**
    This avoids go_stateify relying on `go` being available outside of the
    bazel sandbox.
- **Update Go to 1.25.5**
  Reduce duplication of the version information in various places:
  - Use `go_sdk.from_file` instead of repeating the version encoded in
    `go.mod` in `MODULE.bazel`.
  - Remove `images/gpu/cuda-tests-12-8/install_go.sh`; golang is already
    installed via apt and the version is immaterial.

  Add a workaround to allow `objdump` to be lazily compiled in the manner
  introduced in https://go.dev/issue/71867 when invoked under bazel in
  checkescape.

FUTURE_COPYBARA_INTEGRATE_REVIEW=#12365 from tamird:update-go 6c7f640
PiperOrigin-RevId: 852335920
copybara-service bot pushed a commit that referenced this pull request Jan 6, 2026
- **checkescape: improve error output**
  The output now includes stderr on failure e.g.:
  ```
  checkescape: tools/checkescape/test2/test2.go:98:6: stack: possible split on function entry (2 omitted) → (possible, error running "external/rules_go++go_sdk+main___download_0/bin/go tool objdump bazel-out/k8-fastbuild-ST-04c87098fb12/bin/tools/checkescape/test2/test2.a": exit status 2 (go: no such tool "objdump")) (GOOARCH=amd64, GOOS=linux)
  ```

  Simplify various bits of the implementation while I'm here:
  - Use a set of strings rather than a list to avoid some O(n) operations.
  - Use `CommandContext` to ensure proper cleanup.
  - Remove stderr pipe and goroutine by setting `Stderr` to a
    `bytes.Buffer`.
  - Use `bufio.Scanner` instead of manually calling
    `(*bufio.Reader).ReadString` and handling errors.
  - Remove `NextLine` loop label.
-  **go_stateify: plumb go binary to goimports**
    This avoids go_stateify relying on `go` being available outside of the
    bazel sandbox.
- **Update Go to 1.25.5**
  Reduce duplication of the version information in various places:
  - Use `go_sdk.from_file` instead of repeating the version encoded in
    `go.mod` in `MODULE.bazel`.

  Add a workaround to allow `objdump` to be lazily compiled in the manner
  introduced in https://go.dev/issue/71867 when invoked under bazel in
  checkescape.

FUTURE_COPYBARA_INTEGRATE_REVIEW=#12365 from tamird:update-go 6c7f640
PiperOrigin-RevId: 852335920
copybara-service bot pushed a commit that referenced this pull request Jan 6, 2026
- **checkescape: improve error output**
  The output now includes stderr on failure e.g.:
  ```
  checkescape: tools/checkescape/test2/test2.go:98:6: stack: possible split on function entry (2 omitted) → (possible, error running "external/rules_go++go_sdk+main___download_0/bin/go tool objdump bazel-out/k8-fastbuild-ST-04c87098fb12/bin/tools/checkescape/test2/test2.a": exit status 2 (go: no such tool "objdump")) (GOOARCH=amd64, GOOS=linux)
  ```

  Simplify various bits of the implementation while I'm here:
  - Use a set of strings rather than a list to avoid some O(n) operations.
  - Use `CommandContext` to ensure proper cleanup.
  - Remove stderr pipe and goroutine by setting `Stderr` to a
    `bytes.Buffer`.
  - Use `bufio.Scanner` instead of manually calling
    `(*bufio.Reader).ReadString` and handling errors.
  - Remove `NextLine` loop label.
-  **go_stateify: plumb go binary to goimports**
    This avoids go_stateify relying on `go` being available outside of the
    bazel sandbox.
- **Update Go to 1.25.5**
  Reduce duplication of the version information in various places:
  - Use `go_sdk.from_file` instead of repeating the version encoded in
    `go.mod` in `MODULE.bazel`.

  Add a workaround to allow `objdump` to be lazily compiled in the manner
  introduced in https://go.dev/issue/71867 when invoked under bazel in
  checkescape.

FUTURE_COPYBARA_INTEGRATE_REVIEW=#12365 from tamird:update-go 6c7f640
PiperOrigin-RevId: 852335920
copybara-service bot pushed a commit that referenced this pull request Jan 6, 2026
- **checkescape: improve error output**
  The output now includes stderr on failure e.g.:
  ```
  checkescape: tools/checkescape/test2/test2.go:98:6: stack: possible split on function entry (2 omitted) → (possible, error running "external/rules_go++go_sdk+main___download_0/bin/go tool objdump bazel-out/k8-fastbuild-ST-04c87098fb12/bin/tools/checkescape/test2/test2.a": exit status 2 (go: no such tool "objdump")) (GOOARCH=amd64, GOOS=linux)
  ```

  Simplify various bits of the implementation while I'm here:
  - Use a set of strings rather than a list to avoid some O(n) operations.
  - Use `CommandContext` to ensure proper cleanup.
  - Remove stderr pipe and goroutine by setting `Stderr` to a
    `bytes.Buffer`.
  - Use `bufio.Scanner` instead of manually calling
    `(*bufio.Reader).ReadString` and handling errors.
  - Remove `NextLine` loop label.
-  **go_stateify: plumb go binary to goimports**
    This avoids go_stateify relying on `go` being available outside of the
    bazel sandbox.
- **Update Go to 1.25.5**
  Reduce duplication of the version information in various places:
  - Use `go_sdk.from_file` instead of repeating the version encoded in
    `go.mod` in `MODULE.bazel`.

  Add a workaround to allow `objdump` to be lazily compiled in the manner
  introduced in https://go.dev/issue/71867 when invoked under bazel in
  checkescape.

FUTURE_COPYBARA_INTEGRATE_REVIEW=#12365 from tamird:update-go 6c7f640
PiperOrigin-RevId: 852335920
copybara-service bot pushed a commit that referenced this pull request Jan 6, 2026
- **checkescape: improve error output**
  The output now includes stderr on failure e.g.:
  ```
  checkescape: tools/checkescape/test2/test2.go:98:6: stack: possible split on function entry (2 omitted) → (possible, error running "external/rules_go++go_sdk+main___download_0/bin/go tool objdump bazel-out/k8-fastbuild-ST-04c87098fb12/bin/tools/checkescape/test2/test2.a": exit status 2 (go: no such tool "objdump")) (GOOARCH=amd64, GOOS=linux)
  ```

  Simplify various bits of the implementation while I'm here:
  - Use a set of strings rather than a list to avoid some O(n) operations.
  - Use `CommandContext` to ensure proper cleanup.
  - Remove stderr pipe and goroutine by setting `Stderr` to a
    `bytes.Buffer`.
  - Use `bufio.Scanner` instead of manually calling
    `(*bufio.Reader).ReadString` and handling errors.
  - Remove `NextLine` loop label.
-  **go_stateify: plumb go binary to goimports**
    This avoids go_stateify relying on `go` being available outside of the
    bazel sandbox.
- **Update Go to 1.25.5**
  Reduce duplication of the version information in various places:
  - Use `go_sdk.from_file` instead of repeating the version encoded in
    `go.mod` in `MODULE.bazel`.

  Add a workaround to allow `objdump` to be lazily compiled in the manner
  introduced in https://go.dev/issue/71867 when invoked under bazel in
  checkescape.

FUTURE_COPYBARA_INTEGRATE_REVIEW=#12365 from tamird:update-go 6c7f640
PiperOrigin-RevId: 852335920
copybara-service bot pushed a commit that referenced this pull request Jan 6, 2026
- **checkescape: improve error output**
  The output now includes stderr on failure e.g.:
  ```
  checkescape: tools/checkescape/test2/test2.go:98:6: stack: possible split on function entry (2 omitted) → (possible, error running "external/rules_go++go_sdk+main___download_0/bin/go tool objdump bazel-out/k8-fastbuild-ST-04c87098fb12/bin/tools/checkescape/test2/test2.a": exit status 2 (go: no such tool "objdump")) (GOOARCH=amd64, GOOS=linux)
  ```

  Simplify various bits of the implementation while I'm here:
  - Use a set of strings rather than a list to avoid some O(n) operations.
  - Use `CommandContext` to ensure proper cleanup.
  - Remove stderr pipe and goroutine by setting `Stderr` to a
    `bytes.Buffer`.
  - Use `bufio.Scanner` instead of manually calling
    `(*bufio.Reader).ReadString` and handling errors.
  - Remove `NextLine` loop label.
-  **go_stateify: plumb go binary to goimports**
    This avoids go_stateify relying on `go` being available outside of the
    bazel sandbox.
- **Update Go to 1.25.5**
  Reduce duplication of the version information in various places:
  - Use `go_sdk.from_file` instead of repeating the version encoded in
    `go.mod` in `MODULE.bazel`.

  Add a workaround to allow `objdump` to be lazily compiled in the manner
  introduced in https://go.dev/issue/71867 when invoked under bazel in
  checkescape.

FUTURE_COPYBARA_INTEGRATE_REVIEW=#12365 from tamird:update-go 6c7f640
PiperOrigin-RevId: 852335920
copybara-service bot pushed a commit that referenced this pull request Jan 6, 2026
- **checkescape: improve error output**
  The output now includes stderr on failure e.g.:
  ```
  checkescape: tools/checkescape/test2/test2.go:98:6: stack: possible split on function entry (2 omitted) → (possible, error running "external/rules_go++go_sdk+main___download_0/bin/go tool objdump bazel-out/k8-fastbuild-ST-04c87098fb12/bin/tools/checkescape/test2/test2.a": exit status 2 (go: no such tool "objdump")) (GOOARCH=amd64, GOOS=linux)
  ```

  Simplify various bits of the implementation while I'm here:
  - Use a set of strings rather than a list to avoid some O(n) operations.
  - Use `CommandContext` to ensure proper cleanup.
  - Remove stderr pipe and goroutine by setting `Stderr` to a
    `bytes.Buffer`.
  - Use `bufio.Scanner` instead of manually calling
    `(*bufio.Reader).ReadString` and handling errors.
  - Remove `NextLine` loop label.
-  **go_stateify: plumb go binary to goimports**
    This avoids go_stateify relying on `go` being available outside of the
    bazel sandbox.
- **Update Go to 1.25.5**
  Reduce duplication of the version information in various places:
  - Use `go_sdk.from_file` instead of repeating the version encoded in
    `go.mod` in `MODULE.bazel`.

  Add a workaround to allow `objdump` to be lazily compiled in the manner
  introduced in https://go.dev/issue/71867 when invoked under bazel in
  checkescape.

FUTURE_COPYBARA_INTEGRATE_REVIEW=#12365 from tamird:update-go 6c7f640
PiperOrigin-RevId: 852335920
copybara-service bot pushed a commit that referenced this pull request Jan 7, 2026
- **checkescape: improve error output**
  The output now includes stderr on failure e.g.:
  ```
  checkescape: tools/checkescape/test2/test2.go:98:6: stack: possible split on function entry (2 omitted) → (possible, error running "external/rules_go++go_sdk+main___download_0/bin/go tool objdump bazel-out/k8-fastbuild-ST-04c87098fb12/bin/tools/checkescape/test2/test2.a": exit status 2 (go: no such tool "objdump")) (GOOARCH=amd64, GOOS=linux)
  ```

  Simplify various bits of the implementation while I'm here:
  - Use a set of strings rather than a list to avoid some O(n) operations.
  - Use `CommandContext` to ensure proper cleanup.
  - Remove stderr pipe and goroutine by setting `Stderr` to a
    `bytes.Buffer`.
  - Use `bufio.Scanner` instead of manually calling
    `(*bufio.Reader).ReadString` and handling errors.
  - Remove `NextLine` loop label.
-  **go_stateify: plumb go binary to goimports**
    This avoids go_stateify relying on `go` being available outside of the
    bazel sandbox.
- **Update Go to 1.25.5**
  Reduce duplication of the version information in various places:
  - Use `go_sdk.from_file` instead of repeating the version encoded in
    `go.mod` in `MODULE.bazel`.

  Add a workaround to allow `objdump` to be lazily compiled in the manner
  introduced in https://go.dev/issue/71867 when invoked under bazel in
  checkescape.

FUTURE_COPYBARA_INTEGRATE_REVIEW=#12365 from tamird:update-go 6c7f640
PiperOrigin-RevId: 852335920
copybara-service bot pushed a commit that referenced this pull request Jan 7, 2026
- **checkescape: improve error output**
  The output now includes stderr on failure e.g.:
  ```
  checkescape: tools/checkescape/test2/test2.go:98:6: stack: possible split on function entry (2 omitted) → (possible, error running "external/rules_go++go_sdk+main___download_0/bin/go tool objdump bazel-out/k8-fastbuild-ST-04c87098fb12/bin/tools/checkescape/test2/test2.a": exit status 2 (go: no such tool "objdump")) (GOOARCH=amd64, GOOS=linux)
  ```

  Simplify various bits of the implementation while I'm here:
  - Use a set of strings rather than a list to avoid some O(n) operations.
  - Use `CommandContext` to ensure proper cleanup.
  - Remove stderr pipe and goroutine by setting `Stderr` to a
    `bytes.Buffer`.
  - Use `bufio.Scanner` instead of manually calling
    `(*bufio.Reader).ReadString` and handling errors.
  - Remove `NextLine` loop label.
-  **go_stateify: plumb go binary to goimports**
    This avoids go_stateify relying on `go` being available outside of the
    bazel sandbox.
- **Update Go to 1.25.5**
  Reduce duplication of the version information in various places:
  - Use `go_sdk.from_file` instead of repeating the version encoded in
    `go.mod` in `MODULE.bazel`.

  Add a workaround to allow `objdump` to be lazily compiled in the manner
  introduced in https://go.dev/issue/71867 when invoked under bazel in
  checkescape.

FUTURE_COPYBARA_INTEGRATE_REVIEW=#12365 from tamird:update-go 6c7f640
PiperOrigin-RevId: 852335920
tamird added 7 commits January 7, 2026 05:57
Currently we're seeing infinite retry loops on `docker network create`
which fail with `Error response from daemon: client version 1.52 is too
new. Maximum supported API version is 1.41`. This should prevent that,
though the underlying version mismatch still needs to be investigated.
Currently these routines emit anemic errors on failure such as
```
==================== Test output for //test/image:image_test:
2026/01/07 08:52:20 error running "docker version": exit status 1
==========================================================
```
which is hardly actionable. Separate stdout and stderr for better error
reporting and simplify while I'm here.
The output now includes stderr on failure e.g.:
```
checkescape: tools/checkescape/test2/test2.go:98:6: stack: possible split on function entry (2 omitted) → (possible, error running "external/rules_go++go_sdk+main___download_0/bin/go tool objdump bazel-out/k8-fastbuild-ST-04c87098fb12/bin/tools/checkescape/test2/test2.a": exit status 2 (go: no such tool "objdump")) (GOOARCH=amd64, GOOS=linux)
```

Simplify various bits of the implementation while I'm here:
- Use a set of strings rather than a list to avoid some O(n) operations.
- Use `CommandContext` to ensure proper cleanup.
- Remove stderr pipe and goroutine by setting `Stderr` to a
  `bytes.Buffer`.
- Use `bufio.Scanner` instead of manually calling
  `(*bufio.Reader).ReadString` and handling errors.
- Remove `NextLine` loop label.
This avoids go_stateify relying on `go` being available outside of the
bazel sandbox.
- Use `go_sdk.from_file` instead of repeating the version encoded in
  `go.mod` in `MODULE.bazel`.
- Remove `images/gpu/cuda-tests-12-8/install_go.sh`; golang is already
  installed via apt and the version is immaterial.
Add a workaround to allow `objdump` to be lazily compiled in the manner
introduced in https://go.dev/issue/71867 when invoked under bazel in
checkescape.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants