Go: x/build/cmd/release: go1.13beta1 contains read-only files

Created on 8 Aug 2019  路  3Comments  路  Source: golang/go

Compare the following:

$ tar -ztvf go1.12.7.linux-amd64.tar.gz | head -n 2
drwxr-xr-x root/root         0 2019-07-08 14:29 go/
-rw-r--r-- root/root     55358 2019-07-08 14:29 go/AUTHORS
$ tar -ztvf go1.13beta1.linux-amd64.tar.gz | head -n 2
dr-xr-xr-x root/root         0 2019-06-26 09:39 go/
-r--r--r-- root/root     55389 2019-06-26 09:39 go/AUTHORS

Notice how the u+w bit is missing from the later archive? This makes extracting in a way that preserves the modes as specified in the archive more challenging since writing the AUTHORS file will fail since the parent directory is marked as read-only.

\cc @dmitshur

Builders FrozenDueToAge OS-Linux release-blocker

Most helpful comment

This is due to 02d24fc2528578065b506f07bc6214adcac3be4b, which made GOROOT unwritable during tests on linux-* builders. On the builders where we run all.bash (that is, not MakeOnly), we package the result after the tests have run, so they affect the release.

This is bad in a number of ways. @dmitshur will work on the fix.

All 3 comments

Interesting. This issue only seems to affect linux, since darwin is packed properly (i.e., the u+w bit is present):

$ tar -ztvf go1.13beta1.darwin-amd64.tar.gz | head -n 2
drwxr-xr-x gopher/staff      0 2019-06-26 09:38 go/
-rw-r--r-- gopher/staff  55389 2019-06-26 09:38 go/AUTHORS

This is due to 02d24fc2528578065b506f07bc6214adcac3be4b, which made GOROOT unwritable during tests on linux-* builders. On the builders where we run all.bash (that is, not MakeOnly), we package the result after the tests have run, so they affect the release.

This is bad in a number of ways. @dmitshur will work on the fix.

Change https://golang.org/cl/189537 mentions this issue: cmd/release: create release after make.bash and before all.bash

Was this page helpful?
0 / 5 - 0 ratings