Skip to content

Commit

Permalink
main.star: prepend CIPD epoch to wasmtime, wazero versions
Browse files Browse the repository at this point in the history
The wazero and wasmtime packages are available in infra/3pp/tools as
of crrev.com/c/4995549. In preparation of the switch soon to be done
in crrev.com/c/4995558, prepend the "2@" package epoch (more context
in crrev.com/c/2763964) that their version strings ended up with.

Also factor out the comment explaining how to check the availability
of a given version in CIPD, so we don't need to repeat it 3 times.

For golang/go#61116.
For golang/go#61117.

Change-Id: I1c638aec1782b8d4f15724c0acc97f0323e5f70a
Reviewed-on: https://go-review.googlesource.com/c/build/+/539715
TryBot-Bypass: Dmitri Shuralyov <[email protected]>
TryBot-Bypass: Dmitri Shuralyov <[email protected]>
Reviewed-by: Dmitri Shuralyov <[email protected]>
Auto-Submit: Dmitri Shuralyov <[email protected]>
Reviewed-by: Michael Knyszek <[email protected]>
  • Loading branch information
dmitshur authored and gopherbot committed Nov 3, 2023
1 parent e7f1ebd commit c57b860
Show file tree
Hide file tree
Showing 2 changed files with 26 additions and 27 deletions.
36 changes: 18 additions & 18 deletions generated/cr-buildbucket.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -5605,7 +5605,7 @@ buckets {
' "mode": 1,'
' "project": "go",'
' "tools_cache": "tools",'
' "wasmtime_version": "14.0.4"'
' "wasmtime_version": "2@14.0.4"'
'}'
caches {
name: "git"
Expand Down Expand Up @@ -5651,7 +5651,7 @@ buckets {
' "mode": 1,'
' "project": "go",'
' "tools_cache": "tools",'
' "wazero_version": "1.5.0"'
' "wazero_version": "2@1.5.0"'
'}'
caches {
name: "git"
Expand Down Expand Up @@ -77357,7 +77357,7 @@ buckets {
' "mode": 2,'
' "project": "go",'
' "tools_cache": "tools",'
' "wasmtime_version": "14.0.4"'
' "wasmtime_version": "2@14.0.4"'
'}'
allowed_property_overrides: "go_commit"
caches {
Expand Down Expand Up @@ -77403,7 +77403,7 @@ buckets {
' "shard_id": 0'
' },'
' "tools_cache": "tools",'
' "wasmtime_version": "14.0.4"'
' "wasmtime_version": "2@14.0.4"'
'}'
allowed_property_overrides: "go_commit"
allowed_property_overrides: "test_shard"
Expand Down Expand Up @@ -77446,7 +77446,7 @@ buckets {
' "mode": 2,'
' "project": "go",'
' "tools_cache": "tools",'
' "wazero_version": "1.5.0"'
' "wazero_version": "2@1.5.0"'
'}'
allowed_property_overrides: "go_commit"
caches {
Expand Down Expand Up @@ -77492,7 +77492,7 @@ buckets {
' "shard_id": 0'
' },'
' "tools_cache": "tools",'
' "wazero_version": "1.5.0"'
' "wazero_version": "2@1.5.0"'
'}'
allowed_property_overrides: "go_commit"
allowed_property_overrides: "test_shard"
Expand Down Expand Up @@ -85024,7 +85024,7 @@ buckets {
' "mode": 1,'
' "project": "go",'
' "tools_cache": "tools",'
' "wasmtime_version": "14.0.4"'
' "wasmtime_version": "2@14.0.4"'
'}'
caches {
name: "git"
Expand Down Expand Up @@ -85070,7 +85070,7 @@ buckets {
' "mode": 1,'
' "project": "go",'
' "tools_cache": "tools",'
' "wazero_version": "1.5.0"'
' "wazero_version": "2@1.5.0"'
'}'
caches {
name: "git"
Expand Down Expand Up @@ -92805,7 +92805,7 @@ buckets {
' "mode": 2,'
' "project": "go",'
' "tools_cache": "tools",'
' "wasmtime_version": "14.0.4"'
' "wasmtime_version": "2@14.0.4"'
'}'
allowed_property_overrides: "go_commit"
caches {
Expand Down Expand Up @@ -92851,7 +92851,7 @@ buckets {
' "shard_id": 0'
' },'
' "tools_cache": "tools",'
' "wasmtime_version": "14.0.4"'
' "wasmtime_version": "2@14.0.4"'
'}'
allowed_property_overrides: "go_commit"
allowed_property_overrides: "test_shard"
Expand Down Expand Up @@ -92894,7 +92894,7 @@ buckets {
' "mode": 2,'
' "project": "go",'
' "tools_cache": "tools",'
' "wazero_version": "1.5.0"'
' "wazero_version": "2@1.5.0"'
'}'
allowed_property_overrides: "go_commit"
caches {
Expand Down Expand Up @@ -92940,7 +92940,7 @@ buckets {
' "shard_id": 0'
' },'
' "tools_cache": "tools",'
' "wazero_version": "1.5.0"'
' "wazero_version": "2@1.5.0"'
'}'
allowed_property_overrides: "go_commit"
allowed_property_overrides: "test_shard"
Expand Down Expand Up @@ -97136,7 +97136,7 @@ buckets {
' "mode": 1,'
' "project": "go",'
' "tools_cache": "tools",'
' "wasmtime_version": "14.0.4"'
' "wasmtime_version": "2@14.0.4"'
'}'
caches {
name: "git"
Expand Down Expand Up @@ -97182,7 +97182,7 @@ buckets {
' "mode": 1,'
' "project": "go",'
' "tools_cache": "tools",'
' "wazero_version": "1.5.0"'
' "wazero_version": "2@1.5.0"'
'}'
caches {
name: "git"
Expand Down Expand Up @@ -189908,7 +189908,7 @@ buckets {
' "mode": 2,'
' "project": "go",'
' "tools_cache": "tools",'
' "wasmtime_version": "14.0.4"'
' "wasmtime_version": "2@14.0.4"'
'}'
allowed_property_overrides: "go_commit"
caches {
Expand Down Expand Up @@ -189954,7 +189954,7 @@ buckets {
' "shard_id": 0'
' },'
' "tools_cache": "tools",'
' "wasmtime_version": "14.0.4"'
' "wasmtime_version": "2@14.0.4"'
'}'
allowed_property_overrides: "go_commit"
allowed_property_overrides: "test_shard"
Expand Down Expand Up @@ -189997,7 +189997,7 @@ buckets {
' "mode": 2,'
' "project": "go",'
' "tools_cache": "tools",'
' "wazero_version": "1.5.0"'
' "wazero_version": "2@1.5.0"'
'}'
allowed_property_overrides: "go_commit"
caches {
Expand Down Expand Up @@ -190043,7 +190043,7 @@ buckets {
' "shard_id": 0'
' },'
' "tools_cache": "tools",'
' "wazero_version": "1.5.0"'
' "wazero_version": "2@1.5.0"'
'}'
allowed_property_overrides: "go_commit"
allowed_property_overrides: "test_shard"
Expand Down
17 changes: 8 additions & 9 deletions main.star
Original file line number Diff line number Diff line change
Expand Up @@ -600,6 +600,10 @@ def define_builder(env, project, go_branch_short, builder_type):
# We run GOARCH=wasm builds on linux/amd64 with GOOS/GOARCH set,
# and the applicable Wasm runtime provided as a CIPD dependency.
#
# The availability of a given version in CIPD can be checked with:
# cipd search infra/3pp/tools/{wasm_runtime}/linux-amd64 -tag=version:{version}
# Where wasm_runtime is one of nodejs, wasmtime, wazero.
#
# TODO(dmitshur): We have target_go{os,arch} and by default they would be set to js/wasm.
# However, they're currently only for the coordinator, not build-go and test-only builders,
# so I can't use them as is. Perhaps we'll consider changing that, and then there won't be
Expand All @@ -610,21 +614,16 @@ def define_builder(env, project, go_branch_short, builder_type):
if os == "js":
if suffix != "":
fail("unknown GOOS=js builder suffix: %s" % suffix)
node_versions = {
# Confirm that version is available with: cipd search infra/3pp/tools/nodejs/linux-amd64 -tag=version:{node_version}
18: "[email protected]",
13: "13.2.0",
}
base_props["node_version"] = node_versions[18]
base_props["node_version"] = "[email protected]"
if go_branch_short == "go1.20":
base_props["node_version"] = node_versions[13]
base_props["node_version"] = "13.2.0"
elif os == "wasip1":
if suffix == "wasmtime":
base_props["env"]["GOWASIRUNTIME"] = "wasmtime"
base_props["wasmtime_version"] = "14.0.4"
base_props["wasmtime_version"] = "2@14.0.4"
elif suffix == "wazero":
base_props["env"]["GOWASIRUNTIME"] = "wazero"
base_props["wazero_version"] = "1.5.0"
base_props["wazero_version"] = "2@1.5.0"
else:
fail("unknown GOOS=wasip1 builder suffix: %s" % suffix)

Expand Down

0 comments on commit c57b860

Please sign in to comment.