Skip to content

x/sys: does not contain package golang.org/x/sys/internal/unsafeheader #63412

Closed as not planned

Description

@the-hotmann

What version of Go are you using (go version)?

$ go version
go version go1.21.2 linux/amd64

Does this issue reproduce with the latest release?

Yes, only the lastest (0.13.0)
Works fine with 0.12.0

What operating system and processor architecture are you using (go env)?

go env Output
$ go env
GO111MODULE='on'
GOARCH='amd64'
GOBIN=''
GOCACHE='/root/.cache/go-build'
GOENV='/root/.config/go/env'
GOEXE=''
GOEXPERIMENT=''
GOFLAGS=''
GOHOSTARCH='amd64'
GOHOSTOS='linux'
GOINSECURE=''
GOMODCACHE='/root/go/pkg/mod'
GONOPROXY=''
GONOSUMDB=''
GOOS='linux'
GOPATH='/root/go'
GOPRIVATE=''
GOPROXY='https://proxy.golang.org,direct'
GOROOT='/root/sdk/go1.21.2'
GOSUMDB='sum.golang.org'
GOTMPDIR=''
GOTOOLCHAIN='auto'
GOTOOLDIR='/root/sdk/go1.21.2/pkg/tool/linux_amd64'
GOVCS=''
GOVERSION='go1.21.2'
GCCGO='gccgo'
GOAMD64='v1'
AR='ar'
CC='gcc'
CXX='g++'
CGO_ENABLED='1'
GOMOD='/dev/null'
GOWORK=''
CGO_CFLAGS='-O2 -g'
CGO_CPPFLAGS=''
CGO_CXXFLAGS='-O2 -g'
CGO_FFLAGS='-O2 -g'
CGO_LDFLAGS='-O2 -g'
PKG_CONFIG='pkg-config'
GOGCCFLAGS='-fPIC -m64 -pthread -Wl,--no-gc-sections -fmessage-length=0 -ffile-prefix-map=/tmp/go-build2663969031=/tmp/go-build -gno-record-gcc-switches'

What did you do?

As soo as I want to keep all my packages up-to-date and use go get -u all it also updates x/sys@upgrade to 0.13.0 and then reports that golang.org/x/sys/internal/unsafeheader is missing.

What did you expect to see?

No error? :)

What did you see instead?

This error:

all: module golang.org/x/sys@upgrade found (v0.13.0), but does not contain package golang.org/x/sys/internal/unsafeheader

Activity

  1. added this to the Unreleased milestone on Oct 6, 2023
  2. seankhliao commented on Oct 6, 2023

    @seankhliao
    Member

    It is indeed, no longer there in 0.13.0

  3. shuLhan commented on Oct 13, 2023

    @shuLhan
    Contributor

    @seankhliao Yes, indeed, it is no longer there. But why "go get -u all" return an error if no code use it? I think that is why the OP post it and me comment it here.

    $ cat go.mod
    module github.com/shuLhan/share
    
    go 1.20
    
    require (
            golang.org/x/crypto v0.13.0
            golang.org/x/net v0.15.0
            golang.org/x/sys v0.12.0
            golang.org/x/term v0.12.0
    )
    
    //replace golang.org/x/term => ../../../golang.org/x/term
    
    $ git status
    On branch dev
    Your branch is up to date with 'origin/dev'.
    
    Untracked files:
      (use "git add <file>..." to include in what will be committed)
            testdata/
    
    nothing added to commit but untracked files present (use "git add" to track)
    
    $ go get -u all; echo $?
    go: all: module golang.org/x/sys@upgrade found (v0.13.0), but does not contain package golang.org/x/sys/internal/unsafeheader
    1
    
    $ git --no-pager diff
    
    $
    
  4. seankhliao commented on Oct 13, 2023

    @seankhliao
    Member

    I filed #63528 as a clearer issue

  5. locked and limited conversation to collaborators on Oct 12, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions