diff --git a/Cargo.lock b/Cargo.lock index 9642763ae7ca8..df807218d958b 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -976,13 +976,22 @@ version = "0.17.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "95e65021d89250bbfe7c2791789ced2c4bdc21b0e8bb59c64f3fd6145a5fd678" +[[package]] +name = "capnp" +version = "0.18.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9eddbd729bd9742aa22d29e871a42ffea7f216a4ddbfdaf09ea88150ef2e7f76" +dependencies = [ + "embedded-io", +] + [[package]] name = "capnpc" -version = "0.17.2" +version = "0.18.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fbbc3763fb3e6635188e9cc51ee11a26f8777c553ca377430818dbebaaf6042b" +checksum = "5067f3c8ee94d993d03150153e9a57a6ff330127b1c1ad76475051e1cef79c2d" dependencies = [ - "capnp", + "capnp 0.18.1", ] [[package]] @@ -2329,6 +2338,12 @@ version = "1.9.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "a26ae43d7bcc3b814de94796a5e736d4029efb0ee900c12e2d54c993ad1a1e07" +[[package]] +name = "embedded-io" +version = "0.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "658bbadc628dc286b9ae02f0cb0f5411c056eb7487b72f0083203f115de94060" + [[package]] name = "encode_unicode" version = "0.3.6" @@ -10126,7 +10141,7 @@ dependencies = [ "axum", "axum-server", "camino", - "capnp", + "capnp 0.17.2", "capnpc", "chrono", "clap 4.4.2", diff --git a/cli/.golangci.yml b/cli/.golangci.yml index 2008477cb18bb..4b134cfa92ce7 100644 --- a/cli/.golangci.yml +++ b/cli/.golangci.yml @@ -28,3 +28,5 @@ issues: exclude-use-default: false max-issues-per-linter: 0 max-same-issues: 0 + exclude: + - "func name will be used as hash.Hash.* by other packages, and that stutters; consider calling this" diff --git a/cli/Makefile b/cli/Makefile index da1421d226415..7795426482918 100644 --- a/cli/Makefile +++ b/cli/Makefile @@ -35,6 +35,9 @@ turbo: turbo-prod: cargo build --release --manifest-path ../crates/turborepo/Cargo.toml +turbo-capnp: + cd ../crates/turborepo-lib/src/hash && capnp compile -I std -ogo proto.capnp && mv ./proto.capnp.go ../../../../cli/internal/fs/hash/capnp + go-turbo$(EXT): $(GENERATED_FILES) $(SRC_FILES) go.mod turborepo-ffi-install CGO_ENABLED=1 go build -tags $(GO_TAG) -o go-turbo$(EXT) ./cmd/turbo diff --git a/cli/go.mod b/cli/go.mod index be452d415d9e4..01ceb1dbc9976 100644 --- a/cli/go.mod +++ b/cli/go.mod @@ -1,8 +1,9 @@ module github.com/vercel/turbo/cli -go 1.18 +go 1.20 require ( + capnproto.org/go/capnp/v3 v3.0.0-alpha-29 github.com/AlecAivazis/survey/v2 v2.3.5 github.com/DataDog/zstd v1.5.2 github.com/Masterminds/semver v1.5.0 @@ -35,15 +36,21 @@ require ( github.com/schollz/progressbar/v3 v3.9.0 github.com/segmentio/ksuid v1.0.4 github.com/spf13/cobra v1.3.0 - github.com/stretchr/testify v1.8.0 + github.com/stretchr/testify v1.8.2 github.com/yookoala/realpath v1.0.0 - golang.org/x/sync v0.0.0-20210220032951-036812b2e83c + golang.org/x/sync v0.1.0 golang.org/x/sys v0.5.0 google.golang.org/grpc v1.46.2 google.golang.org/protobuf v1.28.0 gotest.tools/v3 v3.3.0 ) +require ( + github.com/google/go-cmp v0.5.8 // indirect + github.com/tinylib/msgp v1.1.8 // indirect + zenhack.net/go/util v0.0.0-20230414204917-531d38494cf5 // indirect +) + require ( github.com/Masterminds/goutils v1.1.1 // indirect github.com/Masterminds/semver/v3 v3.1.1 // indirect @@ -51,7 +58,6 @@ require ( github.com/armon/go-radix v1.0.0 // indirect github.com/davecgh/go-spew v1.1.1 // indirect github.com/golang/protobuf v1.5.2 // indirect - github.com/google/go-cmp v0.5.8 // indirect github.com/hashicorp/errwrap v1.1.0 // indirect github.com/hashicorp/go-cleanhttp v0.5.2 // indirect github.com/huandu/xstrings v1.3.2 // indirect @@ -70,9 +76,9 @@ require ( github.com/spf13/cast v1.5.0 // indirect github.com/spf13/pflag v1.0.5 // indirect golang.org/x/crypto v0.0.0-20220411220226-7b82a4e95df4 // indirect - golang.org/x/net v0.0.0-20220520000938-2e3eb7b945c2 // indirect - golang.org/x/term v0.0.0-20210927222741-03fcf44c2211 // indirect - golang.org/x/text v0.3.7 // indirect + golang.org/x/net v0.3.0 // indirect + golang.org/x/term v0.3.0 // indirect + golang.org/x/text v0.5.0 // indirect google.golang.org/genproto v0.0.0-20220519153652-3a47de7e79bd // indirect gopkg.in/check.v1 v1.0.0-20200227125254-8fa46927fb4f // indirect gopkg.in/yaml.v3 v3.0.1 // indirect diff --git a/cli/go.sum b/cli/go.sum index 695fa02655d2d..cbce65fdb75f2 100644 --- a/cli/go.sum +++ b/cli/go.sum @@ -1,3 +1,5 @@ +capnproto.org/go/capnp/v3 v3.0.0-alpha-29 h1:ICLhiy4Jmp0d7hLQO+HzFAVIft/oxpPAUPV8tqx+eUE= +capnproto.org/go/capnp/v3 v3.0.0-alpha-29/go.mod h1:+ysMHvOh1EWNOyorxJWs1omhRFiDoKxKkWQACp54jKM= cloud.google.com/go v0.26.0/go.mod h1:aQUYkXzVsufM+DwF1aE+0xfcU+56JwCaLick0ClmMTw= cloud.google.com/go v0.34.0/go.mod h1:aQUYkXzVsufM+DwF1aE+0xfcU+56JwCaLick0ClmMTw= cloud.google.com/go v0.38.0/go.mod h1:990N+gfupTy94rShfmMCWGDn0LpTmnzTp2qbd1dvSRU= @@ -366,6 +368,8 @@ github.com/opentracing/opentracing-go v1.1.0/go.mod h1:UkNAQd3GIcIGf0SeVgPpRdFSt github.com/pascaldekloe/goe v0.0.0-20180627143212-57f6aae5913c/go.mod h1:lzWF7FIEvWOWxwDKqyGYQf6ZUaNfKdP144TG7ZOy1lc= github.com/pascaldekloe/goe v0.1.0/go.mod h1:lzWF7FIEvWOWxwDKqyGYQf6ZUaNfKdP144TG7ZOy1lc= github.com/pelletier/go-toml v1.9.4/go.mod h1:u1nR/EPcESfeI/szUZKdtJ0xRNbUoANCkoOuaOx1Y+c= +github.com/philhofer/fwd v1.1.2 h1:bnDivRJ1EWPjUIRXV5KfORO897HTbpFAQddBdE8t7Gw= +github.com/philhofer/fwd v1.1.2/go.mod h1:qkPdfjR2SIEbspLqpe1tO4n5yICnr2DY7mqEx2tUTP0= github.com/pkg/errors v0.8.0/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= github.com/pkg/errors v0.8.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= github.com/pkg/errors v0.9.1 h1:FEBLx1zS214owpjy7qsBeixbURkuhQAwrK5UwLGTwt4= @@ -426,6 +430,7 @@ github.com/spf13/viper v1.10.0/go.mod h1:SoyBPwAtKDzypXNDFKN5kzH7ppppbGZtls1UpIy github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= github.com/stretchr/objx v0.1.1/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= github.com/stretchr/objx v0.4.0/go.mod h1:YvHI0jy2hoMjB+UWwv71VJQ9isScKT/TqJzVSSt89Yw= +github.com/stretchr/objx v0.5.0/go.mod h1:Yh+to48EsGEfYuaHDzXPcE3xhTkx73EhmCGUpEOglKo= github.com/stretchr/testify v1.2.2/go.mod h1:a8OnRcib4nhh0OaRAV+Yts87kKdq0PP7pXfy6kDkUVs= github.com/stretchr/testify v1.3.0/go.mod h1:M5WIy9Dh21IEIfnGCwXGc5bZfKNJtfHm1UVUgZn+9EI= github.com/stretchr/testify v1.4.0/go.mod h1:j7eGeouHqKxXV5pUuKE4zz7dFj8WfuZ+81PSLYec5m4= @@ -434,9 +439,12 @@ github.com/stretchr/testify v1.6.1/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/ github.com/stretchr/testify v1.7.0/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= github.com/stretchr/testify v1.7.1/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= github.com/stretchr/testify v1.7.2/go.mod h1:R6va5+xMeoiuVRoj+gSkQ7d3FALtqAAGI1FQKckRals= -github.com/stretchr/testify v1.8.0 h1:pSgiaMZlXftHpm5L7V1+rVB+AZJydKsMxsQBIJw4PKk= github.com/stretchr/testify v1.8.0/go.mod h1:yNjHg4UonilssWZ8iaSj1OCr/vHnekPRkoO+kdMU+MU= +github.com/stretchr/testify v1.8.2 h1:+h33VjcLVPDHtOdpUCuF+7gSuG3yGIftsP1YvFihtJ8= +github.com/stretchr/testify v1.8.2/go.mod h1:w2LPCIKwWwSfY2zedu0+kehJoqGctiVI29o6fzry7u4= github.com/subosito/gotenv v1.2.0/go.mod h1:N0PQaV/YGNqwC0u51sEeR/aUtSLEXKX9iv69rRypqCw= +github.com/tinylib/msgp v1.1.8 h1:FCXC1xanKO4I8plpHGH2P7koL/RzZs12l/+r7vakfm0= +github.com/tinylib/msgp v1.1.8/go.mod h1:qkpG+2ldGg4xRFmx+jfTvZPxfGFhi64BcnL9vkCm/Tw= github.com/tv42/httpunix v0.0.0-20150427012821-b75d8614f926/go.mod h1:9ESjWnEqriFuLhtthL60Sar/7RFoluCcXsuvEwTV5KM= github.com/yookoala/realpath v1.0.0 h1:7OA9pj4FZd+oZDsyvXWQvjn5oBdcHRTV44PpdMSuImQ= github.com/yookoala/realpath v1.0.0/go.mod h1:gJJMA9wuX7AcqLy1+ffPatSCySA1FQ2S8Ya9AIoYBpE= @@ -445,6 +453,7 @@ github.com/yuin/goldmark v1.1.27/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9de github.com/yuin/goldmark v1.1.32/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= github.com/yuin/goldmark v1.2.1/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= github.com/yuin/goldmark v1.3.5/go.mod h1:mwnBkeHKe2W/ZEtQ+71ViKU8L12m81fl3OWwC1Zlc8k= +github.com/yuin/goldmark v1.4.13/go.mod h1:6yULJ656Px+3vBD8DxQVa3kxgyrAnzto9xy5taEt/CY= go.etcd.io/etcd/api/v3 v3.5.1/go.mod h1:cbVKeC6lCfl7j/8jBhAK6aIYO9XOjdptoxU/nLQcPvs= go.etcd.io/etcd/client/pkg/v3 v3.5.1/go.mod h1:IJHfcCEKxYu1Os13ZdwCwIUTUVGYTSAM3YSwc9/Ac1g= go.etcd.io/etcd/client/v2 v2.305.1/go.mod h1:pMEacxZW7o8pg4CrFE7pquyCJJzZvkvdD2RibOCCCGs= @@ -474,6 +483,7 @@ golang.org/x/crypto v0.0.0-20200414173820-0848c9571904/go.mod h1:LzIPMQfyMNhhGPh golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= golang.org/x/crypto v0.0.0-20200820211705-5c72a883971a/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= golang.org/x/crypto v0.0.0-20210817164053-32db794688a5/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc= +golang.org/x/crypto v0.0.0-20210921155107-089bfa567519/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc= golang.org/x/crypto v0.0.0-20220131195533-30dcbda58838/go.mod h1:IxCIyHEi3zRg3s0A5j5BB6A9Jmi73HwBIUl50j+osU4= golang.org/x/crypto v0.0.0-20220411220226-7b82a4e95df4 h1:kUhD7nTDoI3fVd9G4ORWrbV5NY0liEs/Jg2pv5f+bBA= golang.org/x/crypto v0.0.0-20220411220226-7b82a4e95df4/go.mod h1:IxCIyHEi3zRg3s0A5j5BB6A9Jmi73HwBIUl50j+osU4= @@ -513,6 +523,8 @@ golang.org/x/mod v0.4.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= golang.org/x/mod v0.4.1/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= golang.org/x/mod v0.4.2/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= golang.org/x/mod v0.5.0/go.mod h1:5OXOZSfqPIIbmVBIIKWRFfZjPR0E5r58TLhUjH0a2Ro= +golang.org/x/mod v0.6.0-dev.0.20220419223038-86c51ed26bb4/go.mod h1:jJ57K6gSWd91VN4djpZkiMVwK6gcyfeH4XE8wZrZaV4= +golang.org/x/mod v0.7.0/go.mod h1:iBbtSCu2XBx23ZKBPSOrRkjjQPZFPuis4dIYUhu/chs= golang.org/x/net v0.0.0-20180724234803-3673e40ba225/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= golang.org/x/net v0.0.0-20180826012351-8a410e7b638d/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= golang.org/x/net v0.0.0-20181023162649-9b4f9f5ad519/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= @@ -555,8 +567,9 @@ golang.org/x/net v0.0.0-20210410081132-afb366fc7cd1/go.mod h1:9tjilg8BloeKEkVJvy golang.org/x/net v0.0.0-20210503060351-7fd8e65b6420/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y= golang.org/x/net v0.0.0-20210813160813-60bc85c4be6d/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y= golang.org/x/net v0.0.0-20211112202133-69e39bad7dc2/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y= -golang.org/x/net v0.0.0-20220520000938-2e3eb7b945c2 h1:NWy5+hlRbC7HK+PmcXVUmW1IMyFce7to56IUvhUFm7Y= -golang.org/x/net v0.0.0-20220520000938-2e3eb7b945c2/go.mod h1:CfG3xpIq0wQ8r1q4Su4UZFWDARRcnwPjda9FqA0JpMk= +golang.org/x/net v0.0.0-20220722155237-a158d28d115b/go.mod h1:XRhObCWvk6IyKnWLug+ECip1KBveYUHfp+8e9klMJ9c= +golang.org/x/net v0.3.0 h1:VWL6FNY2bEEmsGVKabSlHu5Irp34xmMRoqb/9lF9lxk= +golang.org/x/net v0.3.0/go.mod h1:MBQ8lrhLObU/6UmLb4fmbmk5OcyYmqtbGd/9yIeKjEE= golang.org/x/oauth2 v0.0.0-20180821212333-d2e6202438be/go.mod h1:N/0e6XlmueqKjAGxoOufVs8QHGRruUQn6yWY3a++T0U= golang.org/x/oauth2 v0.0.0-20190226205417-e64efc72b421/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw= golang.org/x/oauth2 v0.0.0-20190604053449-0f29369cfe45/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw= @@ -584,8 +597,10 @@ golang.org/x/sync v0.0.0-20200317015054-43a5402ce75a/go.mod h1:RxMgew5VJxzue5/jJ golang.org/x/sync v0.0.0-20200625203802-6e8e738ad208/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20201020160332-67f06af15bc9/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20201207232520-09787c993a3a/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= -golang.org/x/sync v0.0.0-20210220032951-036812b2e83c h1:5KslGYwFpkhGh+Q16bwMP3cOontH8FOep7tGV86Y7SQ= golang.org/x/sync v0.0.0-20210220032951-036812b2e83c/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= +golang.org/x/sync v0.0.0-20220722155255-886fb9371eb4/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= +golang.org/x/sync v0.1.0 h1:wsuoTGHzEhffawBOhz5CYhcrV4IdKZbEyZjBMuTp12o= +golang.org/x/sync v0.1.0/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sys v0.0.0-20180823144017-11551d06cbcc/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20180830151530-49385e6e1522/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20180905080454-ebe1bf3edb33/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= @@ -654,13 +669,17 @@ golang.org/x/sys v0.0.0-20211205182925-97ca703d548d/go.mod h1:oPkhp1MJrh7nUepCBc golang.org/x/sys v0.0.0-20220128215802-99c3d69c2c27/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220422013727-9388b58f7150/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220503163025-988cb79eb6c6/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20220520151302-bc2c85ada10a/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20220722155257-8c9f86f7a55f/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220908164124-27713097b956/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.3.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.5.0 h1:MUK/U/4lj1t1oPg0HfuXDN/Z1wv31ZJ/YcPiGccS4DU= golang.org/x/sys v0.5.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo= golang.org/x/term v0.0.0-20210503060354-a79de5458b56/go.mod h1:tfny5GFUkzUvx4ps4ajbZsCe5lw1metzhBm9T3x7oIY= -golang.org/x/term v0.0.0-20210927222741-03fcf44c2211 h1:JGgROgKl9N8DuW20oFS5gxc+lE67/N3FcwmBPMe7ArY= golang.org/x/term v0.0.0-20210927222741-03fcf44c2211/go.mod h1:jbD1KX2456YbFQfuXm/mYQcufACuNUgVhRMnK/tPxf8= +golang.org/x/term v0.3.0 h1:qoo4akIqOcDME5bhc/NgxUdovd6BSS2uMsVjB56q1xI= +golang.org/x/term v0.3.0/go.mod h1:q750SLmJuPmVoN1blW3UFBPREJfb1KmY3vwxfr+nFDA= golang.org/x/text v0.0.0-20170915032832-14c0d48ead0c/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.1-0.20180807135948-17ff2d5776d2/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= @@ -669,8 +688,9 @@ golang.org/x/text v0.3.3/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= golang.org/x/text v0.3.4/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= golang.org/x/text v0.3.5/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= golang.org/x/text v0.3.6/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= -golang.org/x/text v0.3.7 h1:olpwvP2KacW1ZWvsR7uQhoyTYvKAupfQrRGBFM352Gk= golang.org/x/text v0.3.7/go.mod h1:u+2+/6zg+i71rQMx5EYifcz6MCKuco9NR6JIITiCfzQ= +golang.org/x/text v0.5.0 h1:OLmvp0KP+FVG99Ct/qFiL/Fhk4zp4QQnZ7b2U+5piUM= +golang.org/x/text v0.5.0/go.mod h1:mrYo+phRRbMaCq/xk9113O4dZlRixOauAjOtrjsXDZ8= golang.org/x/time v0.0.0-20181108054448-85acf8d2951c/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= golang.org/x/time v0.0.0-20190308202827-9d24e82272b4/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= golang.org/x/time v0.0.0-20191024005414-555d28b269f0/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= @@ -728,6 +748,8 @@ golang.org/x/tools v0.1.2/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk= golang.org/x/tools v0.1.3/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk= golang.org/x/tools v0.1.4/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk= golang.org/x/tools v0.1.5/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk= +golang.org/x/tools v0.1.12/go.mod h1:hNGJHUnrk76NpqgfD5Aqm5Crs+Hm0VOH/i9J2+nxYbc= +golang.org/x/tools v0.4.0/go.mod h1:UE5sM2OK9E/d67R0ANs2xJizIymRP5gJU295PvKXxjQ= golang.org/x/xerrors v0.0.0-20190717185122-a985d3407aa7/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20191011141410-1b5146add898/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= @@ -916,3 +938,5 @@ honnef.co/go/tools v0.0.1-2020.1.4/go.mod h1:X/FiERA/W4tHapMX5mGpAtMSVEeEUOyHaw9 rsc.io/binaryregexp v0.2.0/go.mod h1:qTv7/COck+e2FymRvadv62gMdZztPaShugOCi3I+8D8= rsc.io/quote/v3 v3.1.0/go.mod h1:yEA65RcK8LyAZtP9Kv3t0HmxON59tX3rD+tICJqUlj0= rsc.io/sampler v1.3.0/go.mod h1:T1hPZKmBbMNahiBKFy5HrXp6adAjACjK9JXDnKaTXpA= +zenhack.net/go/util v0.0.0-20230414204917-531d38494cf5 h1:yksDCGMVzyn3vlyf0GZ3huiF5FFaMGQpQ3UJvR0EoGA= +zenhack.net/go/util v0.0.0-20230414204917-531d38494cf5/go.mod h1:1LtNdPAs8WH+BTcQiZAOo2MIKD/5jyK/u7sZ9ZPe5SE= diff --git a/cli/internal/daemonclient/daemonclient.go b/cli/internal/daemonclient/daemonclient.go index 13e4c7b862f4a..262d11e251ab5 100644 --- a/cli/internal/daemonclient/daemonclient.go +++ b/cli/internal/daemonclient/daemonclient.go @@ -7,7 +7,7 @@ import ( "path/filepath" "github.com/vercel/turbo/cli/internal/daemon/connector" - "github.com/vercel/turbo/cli/internal/fs" + "github.com/vercel/turbo/cli/internal/fs/hash" "github.com/vercel/turbo/cli/internal/turbodprotocol" "github.com/vercel/turbo/cli/internal/turbopath" ) @@ -50,7 +50,7 @@ func (d *DaemonClient) GetChangedOutputs(ctx context.Context, hash string, repoR } // NotifyOutputsWritten implements runcache.OutputWatcher.NotifyOutputsWritten -func (d *DaemonClient) NotifyOutputsWritten(ctx context.Context, hash string, repoRelativeOutputGlobs fs.TaskOutputs, timeSaved int) error { +func (d *DaemonClient) NotifyOutputsWritten(ctx context.Context, hash string, repoRelativeOutputGlobs hash.TaskOutputs, timeSaved int) error { // The daemon expects globs to be unix paths var inclusions []string var exclusions []string diff --git a/cli/internal/fs/hash.go b/cli/internal/fs/hash.go index f1b4dbfc96e7d..79905aae6b2c5 100644 --- a/cli/internal/fs/hash.go +++ b/cli/internal/fs/hash.go @@ -7,10 +7,10 @@ import ( "io" "strconv" - "github.com/vercel/turbo/cli/internal/env" + "github.com/vercel/turbo/cli/internal/fs/hash" + "github.com/vercel/turbo/cli/internal/lockfile" "github.com/vercel/turbo/cli/internal/turbopath" - "github.com/vercel/turbo/cli/internal/util" "github.com/vercel/turbo/cli/internal/xxhash" ) @@ -20,56 +20,24 @@ type LockfilePackages []lockfile.Package // FileHashes is a hashable map of files to the hash of their contents type FileHashes map[turbopath.AnchoredUnixPath]string -// TaskHashable is a hashable representation of a task to be run -type TaskHashable struct { - GlobalHash string - TaskDependencyHashes []string - PackageDir turbopath.AnchoredUnixPath - HashOfFiles string - ExternalDepsHash string - Task string - Outputs TaskOutputs - PassThruArgs []string - Env []string - ResolvedEnvVars env.EnvironmentVariablePairs - PassThroughEnv []string - EnvMode util.EnvMode - DotEnv turbopath.AnchoredUnixPathArray -} - -// GlobalHashable is a hashable representation of global dependencies for tasks -type GlobalHashable struct { - GlobalCacheKey string - GlobalFileHashMap map[turbopath.AnchoredUnixPath]string - RootExternalDepsHash string - Env []string - ResolvedEnvVars env.EnvironmentVariablePairs - PassThroughEnv []string - EnvMode util.EnvMode - FrameworkInference bool - - // NOTE! This field is _explicitly_ ordered and should not be sorted. - DotEnv turbopath.AnchoredUnixPathArray -} - // HashLockfilePackages hashes a list of packages func HashLockfilePackages(packages LockfilePackages) (string, error) { - return hashObject(packages) + return hash.HashLockfilePackages(packages) } // HashFileHashes produces a single hash for a set of file hashes func HashFileHashes(hashes FileHashes) (string, error) { - return hashObject(hashes) + return hash.HashFileHashes(hashes) } // HashTask produces the hash for a particular task -func HashTask(task *TaskHashable) (string, error) { - return hashObject(task) +func HashTask(task *hash.TaskHashable) (string, error) { + return hash.HashTaskHashable(task) } // HashGlobal produces the global hash value to be incorporated in every task hash -func HashGlobal(global GlobalHashable) (string, error) { - return hashObject(global) +func HashGlobal(global hash.GlobalHashable) (string, error) { + return hash.HashGlobalHashable(&global) } // hashObject is the internal generic hash function. It should not be used directly, diff --git a/cli/internal/fs/hash/capnp.go b/cli/internal/fs/hash/capnp.go new file mode 100644 index 0000000000000..c60d5a951dfd8 --- /dev/null +++ b/cli/internal/fs/hash/capnp.go @@ -0,0 +1,458 @@ +// Package hash contains the capnp schema and hashing functions for the turbo cache +// +// it depends on the generated capnp schema in ./capnp. to regenerate the schema, +// you need the capnp binary as well as capnpc-go available in your path. then run: +// +// capnp compile -I std -ogo proto.capnp +// +// in crates/turborepo-lib/src/hash or run `make turbo-capnp` in the `cli` directory. +package hash + +import ( + "encoding/hex" + "sort" + + capnp "capnproto.org/go/capnp/v3" + "github.com/vercel/turbo/cli/internal/env" + turbo_capnp "github.com/vercel/turbo/cli/internal/fs/hash/capnp" + "github.com/vercel/turbo/cli/internal/lockfile" + "github.com/vercel/turbo/cli/internal/turbopath" + "github.com/vercel/turbo/cli/internal/util" + "github.com/vercel/turbo/cli/internal/xxhash" +) + +// TaskHashable is a hashable representation of a task to be run +type TaskHashable struct { + GlobalHash string + TaskDependencyHashes []string + HashOfFiles string + ExternalDepsHash string + + PackageDir turbopath.AnchoredUnixPath + Task string + Outputs TaskOutputs + PassThruArgs []string + + Env []string + ResolvedEnvVars env.EnvironmentVariablePairs + PassThroughEnv []string + EnvMode util.EnvMode + DotEnv turbopath.AnchoredUnixPathArray +} + +// GlobalHashable is a hashable representation of global dependencies for tasks +type GlobalHashable struct { + GlobalCacheKey string + GlobalFileHashMap map[turbopath.AnchoredUnixPath]string + RootExternalDepsHash string + Env []string + ResolvedEnvVars env.EnvironmentVariablePairs + PassThroughEnv []string + EnvMode util.EnvMode + FrameworkInference bool + + // NOTE! This field is _explicitly_ ordered and should not be sorted. + DotEnv turbopath.AnchoredUnixPathArray +} + +// TaskOutputs represents the patterns for including and excluding files from outputs +type TaskOutputs struct { + Inclusions []string + Exclusions []string +} + +// Sort contents of task outputs +func (to *TaskOutputs) Sort() { + sort.Strings(to.Inclusions) + sort.Strings(to.Exclusions) +} + +// HashTaskHashable performs the hash for a TaskHashable, using capnproto for stable cross platform / language hashing +// +// NOTE: This function is _explicitly_ ordered and should not be sorted. +// +// Order is important for the hash, and is as follows: +// - GlobalHash +// - PackageDir +// - HashOfFiles +// - ExternalDepsHash +// - Task +// - EnvMode +// - Outputs +// - TaskDependencyHashes +// - PassThruArgs +// - Env +// - PassThroughEnv +// - DotEnv +// - ResolvedEnvVars +func HashTaskHashable(task *TaskHashable) (string, error) { + arena := capnp.SingleSegment(nil) + + _, seg, err := capnp.NewMessage(arena) + if err != nil { + return "", err + } + + taskMsg, err := turbo_capnp.NewRootTaskHashable(seg) + if err != nil { + return "", err + } + + err = taskMsg.SetGlobalHash(task.GlobalHash) + if err != nil { + return "", err + } + + err = taskMsg.SetPackageDir(task.PackageDir.ToString()) + if err != nil { + return "", err + } + + err = taskMsg.SetHashOfFiles(task.HashOfFiles) + if err != nil { + return "", err + } + + err = taskMsg.SetExternalDepsHash(task.ExternalDepsHash) + if err != nil { + return "", err + } + + err = taskMsg.SetTask(task.Task) + if err != nil { + return "", err + } + + { + var envMode turbo_capnp.TaskHashable_EnvMode + switch task.EnvMode { + case util.Infer: + panic("task inferred status should have already been resolved") + case util.Loose: + envMode = turbo_capnp.TaskHashable_EnvMode_loose + case util.Strict: + envMode = turbo_capnp.TaskHashable_EnvMode_strict + } + + taskMsg.SetEnvMode(envMode) + } + + { + deps, err := taskMsg.NewOutputs() + if err != nil { + return "", err + } + + err = assignList(task.Outputs.Inclusions, deps.SetInclusions, seg) + if err != nil { + return "", err + } + + err = assignList(task.Outputs.Exclusions, deps.SetExclusions, seg) + if err != nil { + return "", err + } + + err = taskMsg.SetOutputs(deps) + if err != nil { + return "", err + } + } + + err = assignList(task.TaskDependencyHashes, taskMsg.SetTaskDependencyHashes, seg) + if err != nil { + return "", err + } + + err = assignList(task.PassThruArgs, taskMsg.SetPassThruArgs, seg) + if err != nil { + return "", err + } + + err = assignList(task.Env, taskMsg.SetEnv, seg) + if err != nil { + return "", err + } + + err = assignList(task.PassThroughEnv, taskMsg.SetPassThruEnv, seg) + if err != nil { + return "", err + } + + err = assignAnchoredUnixArray(task.DotEnv, taskMsg.SetDotEnv, seg) + if err != nil { + return "", err + } + + err = assignList(task.ResolvedEnvVars, taskMsg.SetResolvedEnvVars, seg) + if err != nil { + return "", err + } + + return HashMessage(taskMsg.Message()) +} + +// HashGlobalHashable performs the hash for a GlobalHashable, using capnproto for stable cross platform / language hashing +// +// NOTE: This function is _explicitly_ ordered and should not be sorted. +// +// Order is important for the hash, and is as follows: +// - GlobalCacheKey +// - GlobalFileHashMap +// - RootExternalDepsHash +// - Env +// - ResolvedEnvVars +// - PassThroughEnv +// - EnvMode +// - FrameworkInference +// - DotEnv +func HashGlobalHashable(global *GlobalHashable) (string, error) { + arena := capnp.SingleSegment(nil) + + _, seg, err := capnp.NewMessage(arena) + if err != nil { + return "", err + } + + globalMsg, err := turbo_capnp.NewRootGlobalHashable(seg) + if err != nil { + return "", err + } + + err = globalMsg.SetGlobalCacheKey(global.GlobalCacheKey) + if err != nil { + return "", err + } + + { + entries, err := globalMsg.NewGlobalFileHashMap(int32(len(global.GlobalFileHashMap))) + if err != nil { + return "", err + } + + err = assignSortedHashMap(global.GlobalFileHashMap, func(i int, key string, value string) error { + entry := entries.At(i) + + err = entry.SetKey(key) + if err != nil { + return err + } + + err = entry.SetValue(value) + if err != nil { + return err + } + + return nil + }) + if err != nil { + return "", err + } + } + + err = globalMsg.SetRootExternalDepsHash(global.RootExternalDepsHash) + if err != nil { + return "", err + } + + err = assignList(global.Env, globalMsg.SetEnv, seg) + if err != nil { + return "", err + } + + err = assignList(global.ResolvedEnvVars, globalMsg.SetResolvedEnvVars, seg) + if err != nil { + return "", err + } + + err = assignList(global.PassThroughEnv, globalMsg.SetPassThroughEnv, seg) + if err != nil { + return "", err + } + + { + var envMode turbo_capnp.GlobalHashable_EnvMode + switch global.EnvMode { + case util.Infer: + envMode = turbo_capnp.GlobalHashable_EnvMode_infer + case util.Loose: + envMode = turbo_capnp.GlobalHashable_EnvMode_loose + case util.Strict: + envMode = turbo_capnp.GlobalHashable_EnvMode_strict + } + + globalMsg.SetEnvMode(envMode) + } + + globalMsg.SetFrameworkInference(global.FrameworkInference) + + err = assignAnchoredUnixArray(global.DotEnv, globalMsg.SetDotEnv, seg) + if err != nil { + return "", err + } + + return HashMessage(globalMsg.Message()) +} + +// HashLockfilePackages hashes lockfile packages +func HashLockfilePackages(packages []lockfile.Package) (string, error) { + arena := capnp.SingleSegment(nil) + + _, seg, err := capnp.NewMessage(arena) + if err != nil { + return "", err + } + + globalMsg, err := turbo_capnp.NewRootLockFilePackages(seg) + if err != nil { + return "", err + } + + entries, err := globalMsg.NewPackages(int32(len(packages))) + if err != nil { + return "", err + } + for i, pkg := range packages { + entry := entries.At(i) + + err = entry.SetKey(pkg.Key) + if err != nil { + return "", err + } + + err = entry.SetVersion(pkg.Version) + if err != nil { + return "", err + } + + entry.SetFound(pkg.Found) + } + + return HashMessage(globalMsg.Message()) +} + +// HashFileHashes hashes files +func HashFileHashes(fileHashes map[turbopath.AnchoredUnixPath]string) (string, error) { + arena := capnp.SingleSegment(nil) + + _, seg, err := capnp.NewMessage(arena) + if err != nil { + return "", err + } + + globalMsg, err := turbo_capnp.NewRootFileHashes(seg) + if err != nil { + return "", err + } + + { + entries, err := globalMsg.NewFileHashes(int32(len(fileHashes))) + if err != nil { + return "", err + } + + err = assignSortedHashMap(fileHashes, func(i int, key string, value string) error { + entry := entries.At(i) + + err = entry.SetKey(key) + if err != nil { + return err + } + + err = entry.SetValue(value) + if err != nil { + return err + } + + return nil + }) + if err != nil { + return "", err + } + } + + return HashMessage(globalMsg.Message()) +} + +// HashMessage hashes a capnp message using xxhash +func HashMessage(msg *capnp.Message) (string, error) { + root, err := msg.Root() + if err != nil { + return "", err + } + + bytes, err := capnp.Canonicalize(root.Struct()) + if err != nil { + return "", err + } + + // _ = turbopath.AbsoluteSystemPath(".turbo/go-hash").WriteFile(bytes, 0644) + + digest := xxhash.New() + _, err = digest.Write(bytes) + if err != nil { + return "", err + } + + out := digest.Sum(nil) + + return hex.EncodeToString(out), nil +} + +// assignSortedHashMap gets a list of key value pairs and then sort them by key +// to do this we need three lists, one for the keys, one for the string representation of the keys, +// and one for the indices of the keys +func assignSortedHashMap(packages map[turbopath.AnchoredUnixPath]string, setEntry func(int, string, string) error) error { + keys := make([]turbopath.AnchoredUnixPath, len(packages)) + keyStrs := make([]string, len(packages)) + keyIndices := make([]int, len(packages)) + + i := 0 + for k := range packages { + keys[i] = k + keyStrs[i] = k.ToString() + keyIndices[i] = i + i++ + } + + sort.Slice(keyIndices, func(i, j int) bool { + return keyStrs[keyIndices[i]] < keyStrs[keyIndices[j]] + }) + + for i, idx := range keyIndices { + err := setEntry(i, keyStrs[idx], packages[keys[idx]]) + if err != nil { + return err + } + } + + return nil +} + +func assignList(list []string, fn func(capnp.TextList) error, seg *capnp.Segment) error { + textList, err := capnp.NewTextList(seg, int32(len(list))) + if err != nil { + return err + } + for i, v := range list { + err = textList.Set(i, v) + if err != nil { + return err + } + } + return fn(textList) +} + +func assignAnchoredUnixArray(paths turbopath.AnchoredUnixPathArray, fn func(capnp.TextList) error, seg *capnp.Segment) error { + textList, err := capnp.NewTextList(seg, int32(len(paths))) + if err != nil { + return err + } + for i, v := range paths { + err = textList.Set(i, v.ToString()) + if err != nil { + return err + } + } + return fn(textList) +} diff --git a/cli/internal/fs/hash/capnp/proto.capnp.go b/cli/internal/fs/hash/capnp/proto.capnp.go new file mode 100644 index 0000000000000..33dbd555208c3 --- /dev/null +++ b/cli/internal/fs/hash/capnp/proto.capnp.go @@ -0,0 +1,1357 @@ +// Code generated by capnpc-go. DO NOT EDIT. + +package capnp + +import ( + capnp "capnproto.org/go/capnp/v3" + text "capnproto.org/go/capnp/v3/encoding/text" + schemas "capnproto.org/go/capnp/v3/schemas" +) + +type TaskHashable capnp.Struct + +// TaskHashable_TypeID is the unique identifier for the type TaskHashable. +const TaskHashable_TypeID = 0xe1f09ceb4ef5e479 + +func NewTaskHashable(s *capnp.Segment) (TaskHashable, error) { + st, err := capnp.NewStruct(s, capnp.ObjectSize{DataSize: 8, PointerCount: 12}) + return TaskHashable(st), err +} + +func NewRootTaskHashable(s *capnp.Segment) (TaskHashable, error) { + st, err := capnp.NewRootStruct(s, capnp.ObjectSize{DataSize: 8, PointerCount: 12}) + return TaskHashable(st), err +} + +func ReadRootTaskHashable(msg *capnp.Message) (TaskHashable, error) { + root, err := msg.Root() + return TaskHashable(root.Struct()), err +} + +func (s TaskHashable) String() string { + str, _ := text.Marshal(0xe1f09ceb4ef5e479, capnp.Struct(s)) + return str +} + +func (s TaskHashable) EncodeAsPtr(seg *capnp.Segment) capnp.Ptr { + return capnp.Struct(s).EncodeAsPtr(seg) +} + +func (TaskHashable) DecodeFromPtr(p capnp.Ptr) TaskHashable { + return TaskHashable(capnp.Struct{}.DecodeFromPtr(p)) +} + +func (s TaskHashable) ToPtr() capnp.Ptr { + return capnp.Struct(s).ToPtr() +} +func (s TaskHashable) IsValid() bool { + return capnp.Struct(s).IsValid() +} + +func (s TaskHashable) Message() *capnp.Message { + return capnp.Struct(s).Message() +} + +func (s TaskHashable) Segment() *capnp.Segment { + return capnp.Struct(s).Segment() +} +func (s TaskHashable) GlobalHash() (string, error) { + p, err := capnp.Struct(s).Ptr(0) + return p.Text(), err +} + +func (s TaskHashable) HasGlobalHash() bool { + return capnp.Struct(s).HasPtr(0) +} + +func (s TaskHashable) GlobalHashBytes() ([]byte, error) { + p, err := capnp.Struct(s).Ptr(0) + return p.TextBytes(), err +} + +func (s TaskHashable) SetGlobalHash(v string) error { + return capnp.Struct(s).SetText(0, v) +} + +func (s TaskHashable) TaskDependencyHashes() (capnp.TextList, error) { + p, err := capnp.Struct(s).Ptr(1) + return capnp.TextList(p.List()), err +} + +func (s TaskHashable) HasTaskDependencyHashes() bool { + return capnp.Struct(s).HasPtr(1) +} + +func (s TaskHashable) SetTaskDependencyHashes(v capnp.TextList) error { + return capnp.Struct(s).SetPtr(1, v.ToPtr()) +} + +// NewTaskDependencyHashes sets the taskDependencyHashes field to a newly +// allocated capnp.TextList, preferring placement in s's segment. +func (s TaskHashable) NewTaskDependencyHashes(n int32) (capnp.TextList, error) { + l, err := capnp.NewTextList(capnp.Struct(s).Segment(), n) + if err != nil { + return capnp.TextList{}, err + } + err = capnp.Struct(s).SetPtr(1, l.ToPtr()) + return l, err +} +func (s TaskHashable) PackageDir() (string, error) { + p, err := capnp.Struct(s).Ptr(2) + return p.Text(), err +} + +func (s TaskHashable) HasPackageDir() bool { + return capnp.Struct(s).HasPtr(2) +} + +func (s TaskHashable) PackageDirBytes() ([]byte, error) { + p, err := capnp.Struct(s).Ptr(2) + return p.TextBytes(), err +} + +func (s TaskHashable) SetPackageDir(v string) error { + return capnp.Struct(s).SetText(2, v) +} + +func (s TaskHashable) HashOfFiles() (string, error) { + p, err := capnp.Struct(s).Ptr(3) + return p.Text(), err +} + +func (s TaskHashable) HasHashOfFiles() bool { + return capnp.Struct(s).HasPtr(3) +} + +func (s TaskHashable) HashOfFilesBytes() ([]byte, error) { + p, err := capnp.Struct(s).Ptr(3) + return p.TextBytes(), err +} + +func (s TaskHashable) SetHashOfFiles(v string) error { + return capnp.Struct(s).SetText(3, v) +} + +func (s TaskHashable) ExternalDepsHash() (string, error) { + p, err := capnp.Struct(s).Ptr(4) + return p.Text(), err +} + +func (s TaskHashable) HasExternalDepsHash() bool { + return capnp.Struct(s).HasPtr(4) +} + +func (s TaskHashable) ExternalDepsHashBytes() ([]byte, error) { + p, err := capnp.Struct(s).Ptr(4) + return p.TextBytes(), err +} + +func (s TaskHashable) SetExternalDepsHash(v string) error { + return capnp.Struct(s).SetText(4, v) +} + +func (s TaskHashable) Task() (string, error) { + p, err := capnp.Struct(s).Ptr(5) + return p.Text(), err +} + +func (s TaskHashable) HasTask() bool { + return capnp.Struct(s).HasPtr(5) +} + +func (s TaskHashable) TaskBytes() ([]byte, error) { + p, err := capnp.Struct(s).Ptr(5) + return p.TextBytes(), err +} + +func (s TaskHashable) SetTask(v string) error { + return capnp.Struct(s).SetText(5, v) +} + +func (s TaskHashable) Outputs() (TaskOutputs, error) { + p, err := capnp.Struct(s).Ptr(6) + return TaskOutputs(p.Struct()), err +} + +func (s TaskHashable) HasOutputs() bool { + return capnp.Struct(s).HasPtr(6) +} + +func (s TaskHashable) SetOutputs(v TaskOutputs) error { + return capnp.Struct(s).SetPtr(6, capnp.Struct(v).ToPtr()) +} + +// NewOutputs sets the outputs field to a newly +// allocated TaskOutputs struct, preferring placement in s's segment. +func (s TaskHashable) NewOutputs() (TaskOutputs, error) { + ss, err := NewTaskOutputs(capnp.Struct(s).Segment()) + if err != nil { + return TaskOutputs{}, err + } + err = capnp.Struct(s).SetPtr(6, capnp.Struct(ss).ToPtr()) + return ss, err +} + +func (s TaskHashable) PassThruArgs() (capnp.TextList, error) { + p, err := capnp.Struct(s).Ptr(7) + return capnp.TextList(p.List()), err +} + +func (s TaskHashable) HasPassThruArgs() bool { + return capnp.Struct(s).HasPtr(7) +} + +func (s TaskHashable) SetPassThruArgs(v capnp.TextList) error { + return capnp.Struct(s).SetPtr(7, v.ToPtr()) +} + +// NewPassThruArgs sets the passThruArgs field to a newly +// allocated capnp.TextList, preferring placement in s's segment. +func (s TaskHashable) NewPassThruArgs(n int32) (capnp.TextList, error) { + l, err := capnp.NewTextList(capnp.Struct(s).Segment(), n) + if err != nil { + return capnp.TextList{}, err + } + err = capnp.Struct(s).SetPtr(7, l.ToPtr()) + return l, err +} +func (s TaskHashable) Env() (capnp.TextList, error) { + p, err := capnp.Struct(s).Ptr(8) + return capnp.TextList(p.List()), err +} + +func (s TaskHashable) HasEnv() bool { + return capnp.Struct(s).HasPtr(8) +} + +func (s TaskHashable) SetEnv(v capnp.TextList) error { + return capnp.Struct(s).SetPtr(8, v.ToPtr()) +} + +// NewEnv sets the env field to a newly +// allocated capnp.TextList, preferring placement in s's segment. +func (s TaskHashable) NewEnv(n int32) (capnp.TextList, error) { + l, err := capnp.NewTextList(capnp.Struct(s).Segment(), n) + if err != nil { + return capnp.TextList{}, err + } + err = capnp.Struct(s).SetPtr(8, l.ToPtr()) + return l, err +} +func (s TaskHashable) ResolvedEnvVars() (capnp.TextList, error) { + p, err := capnp.Struct(s).Ptr(9) + return capnp.TextList(p.List()), err +} + +func (s TaskHashable) HasResolvedEnvVars() bool { + return capnp.Struct(s).HasPtr(9) +} + +func (s TaskHashable) SetResolvedEnvVars(v capnp.TextList) error { + return capnp.Struct(s).SetPtr(9, v.ToPtr()) +} + +// NewResolvedEnvVars sets the resolvedEnvVars field to a newly +// allocated capnp.TextList, preferring placement in s's segment. +func (s TaskHashable) NewResolvedEnvVars(n int32) (capnp.TextList, error) { + l, err := capnp.NewTextList(capnp.Struct(s).Segment(), n) + if err != nil { + return capnp.TextList{}, err + } + err = capnp.Struct(s).SetPtr(9, l.ToPtr()) + return l, err +} +func (s TaskHashable) PassThruEnv() (capnp.TextList, error) { + p, err := capnp.Struct(s).Ptr(10) + return capnp.TextList(p.List()), err +} + +func (s TaskHashable) HasPassThruEnv() bool { + return capnp.Struct(s).HasPtr(10) +} + +func (s TaskHashable) SetPassThruEnv(v capnp.TextList) error { + return capnp.Struct(s).SetPtr(10, v.ToPtr()) +} + +// NewPassThruEnv sets the passThruEnv field to a newly +// allocated capnp.TextList, preferring placement in s's segment. +func (s TaskHashable) NewPassThruEnv(n int32) (capnp.TextList, error) { + l, err := capnp.NewTextList(capnp.Struct(s).Segment(), n) + if err != nil { + return capnp.TextList{}, err + } + err = capnp.Struct(s).SetPtr(10, l.ToPtr()) + return l, err +} +func (s TaskHashable) EnvMode() TaskHashable_EnvMode { + return TaskHashable_EnvMode(capnp.Struct(s).Uint16(0)) +} + +func (s TaskHashable) SetEnvMode(v TaskHashable_EnvMode) { + capnp.Struct(s).SetUint16(0, uint16(v)) +} + +func (s TaskHashable) DotEnv() (capnp.TextList, error) { + p, err := capnp.Struct(s).Ptr(11) + return capnp.TextList(p.List()), err +} + +func (s TaskHashable) HasDotEnv() bool { + return capnp.Struct(s).HasPtr(11) +} + +func (s TaskHashable) SetDotEnv(v capnp.TextList) error { + return capnp.Struct(s).SetPtr(11, v.ToPtr()) +} + +// NewDotEnv sets the dotEnv field to a newly +// allocated capnp.TextList, preferring placement in s's segment. +func (s TaskHashable) NewDotEnv(n int32) (capnp.TextList, error) { + l, err := capnp.NewTextList(capnp.Struct(s).Segment(), n) + if err != nil { + return capnp.TextList{}, err + } + err = capnp.Struct(s).SetPtr(11, l.ToPtr()) + return l, err +} + +// TaskHashable_List is a list of TaskHashable. +type TaskHashable_List = capnp.StructList[TaskHashable] + +// NewTaskHashable creates a new list of TaskHashable. +func NewTaskHashable_List(s *capnp.Segment, sz int32) (TaskHashable_List, error) { + l, err := capnp.NewCompositeList(s, capnp.ObjectSize{DataSize: 8, PointerCount: 12}, sz) + return capnp.StructList[TaskHashable](l), err +} + +// TaskHashable_Future is a wrapper for a TaskHashable promised by a client call. +type TaskHashable_Future struct{ *capnp.Future } + +func (f TaskHashable_Future) Struct() (TaskHashable, error) { + p, err := f.Future.Ptr() + return TaskHashable(p.Struct()), err +} +func (p TaskHashable_Future) Outputs() TaskOutputs_Future { + return TaskOutputs_Future{Future: p.Future.Field(6, nil)} +} + +type TaskHashable_EnvMode uint16 + +// TaskHashable_EnvMode_TypeID is the unique identifier for the type TaskHashable_EnvMode. +const TaskHashable_EnvMode_TypeID = 0x8dc08a1d29f69b16 + +// Values of TaskHashable_EnvMode. +const ( + TaskHashable_EnvMode_loose TaskHashable_EnvMode = 0 + TaskHashable_EnvMode_strict TaskHashable_EnvMode = 1 +) + +// String returns the enum's constant name. +func (c TaskHashable_EnvMode) String() string { + switch c { + case TaskHashable_EnvMode_loose: + return "loose" + case TaskHashable_EnvMode_strict: + return "strict" + + default: + return "" + } +} + +// TaskHashable_EnvModeFromString returns the enum value with a name, +// or the zero value if there's no such value. +func TaskHashable_EnvModeFromString(c string) TaskHashable_EnvMode { + switch c { + case "loose": + return TaskHashable_EnvMode_loose + case "strict": + return TaskHashable_EnvMode_strict + + default: + return 0 + } +} + +type TaskHashable_EnvMode_List = capnp.EnumList[TaskHashable_EnvMode] + +func NewTaskHashable_EnvMode_List(s *capnp.Segment, sz int32) (TaskHashable_EnvMode_List, error) { + return capnp.NewEnumList[TaskHashable_EnvMode](s, sz) +} + +type TaskOutputs capnp.Struct + +// TaskOutputs_TypeID is the unique identifier for the type TaskOutputs. +const TaskOutputs_TypeID = 0xd58300fce8aba267 + +func NewTaskOutputs(s *capnp.Segment) (TaskOutputs, error) { + st, err := capnp.NewStruct(s, capnp.ObjectSize{DataSize: 0, PointerCount: 2}) + return TaskOutputs(st), err +} + +func NewRootTaskOutputs(s *capnp.Segment) (TaskOutputs, error) { + st, err := capnp.NewRootStruct(s, capnp.ObjectSize{DataSize: 0, PointerCount: 2}) + return TaskOutputs(st), err +} + +func ReadRootTaskOutputs(msg *capnp.Message) (TaskOutputs, error) { + root, err := msg.Root() + return TaskOutputs(root.Struct()), err +} + +func (s TaskOutputs) String() string { + str, _ := text.Marshal(0xd58300fce8aba267, capnp.Struct(s)) + return str +} + +func (s TaskOutputs) EncodeAsPtr(seg *capnp.Segment) capnp.Ptr { + return capnp.Struct(s).EncodeAsPtr(seg) +} + +func (TaskOutputs) DecodeFromPtr(p capnp.Ptr) TaskOutputs { + return TaskOutputs(capnp.Struct{}.DecodeFromPtr(p)) +} + +func (s TaskOutputs) ToPtr() capnp.Ptr { + return capnp.Struct(s).ToPtr() +} +func (s TaskOutputs) IsValid() bool { + return capnp.Struct(s).IsValid() +} + +func (s TaskOutputs) Message() *capnp.Message { + return capnp.Struct(s).Message() +} + +func (s TaskOutputs) Segment() *capnp.Segment { + return capnp.Struct(s).Segment() +} +func (s TaskOutputs) Inclusions() (capnp.TextList, error) { + p, err := capnp.Struct(s).Ptr(0) + return capnp.TextList(p.List()), err +} + +func (s TaskOutputs) HasInclusions() bool { + return capnp.Struct(s).HasPtr(0) +} + +func (s TaskOutputs) SetInclusions(v capnp.TextList) error { + return capnp.Struct(s).SetPtr(0, v.ToPtr()) +} + +// NewInclusions sets the inclusions field to a newly +// allocated capnp.TextList, preferring placement in s's segment. +func (s TaskOutputs) NewInclusions(n int32) (capnp.TextList, error) { + l, err := capnp.NewTextList(capnp.Struct(s).Segment(), n) + if err != nil { + return capnp.TextList{}, err + } + err = capnp.Struct(s).SetPtr(0, l.ToPtr()) + return l, err +} +func (s TaskOutputs) Exclusions() (capnp.TextList, error) { + p, err := capnp.Struct(s).Ptr(1) + return capnp.TextList(p.List()), err +} + +func (s TaskOutputs) HasExclusions() bool { + return capnp.Struct(s).HasPtr(1) +} + +func (s TaskOutputs) SetExclusions(v capnp.TextList) error { + return capnp.Struct(s).SetPtr(1, v.ToPtr()) +} + +// NewExclusions sets the exclusions field to a newly +// allocated capnp.TextList, preferring placement in s's segment. +func (s TaskOutputs) NewExclusions(n int32) (capnp.TextList, error) { + l, err := capnp.NewTextList(capnp.Struct(s).Segment(), n) + if err != nil { + return capnp.TextList{}, err + } + err = capnp.Struct(s).SetPtr(1, l.ToPtr()) + return l, err +} + +// TaskOutputs_List is a list of TaskOutputs. +type TaskOutputs_List = capnp.StructList[TaskOutputs] + +// NewTaskOutputs creates a new list of TaskOutputs. +func NewTaskOutputs_List(s *capnp.Segment, sz int32) (TaskOutputs_List, error) { + l, err := capnp.NewCompositeList(s, capnp.ObjectSize{DataSize: 0, PointerCount: 2}, sz) + return capnp.StructList[TaskOutputs](l), err +} + +// TaskOutputs_Future is a wrapper for a TaskOutputs promised by a client call. +type TaskOutputs_Future struct{ *capnp.Future } + +func (f TaskOutputs_Future) Struct() (TaskOutputs, error) { + p, err := f.Future.Ptr() + return TaskOutputs(p.Struct()), err +} + +type GlobalHashable capnp.Struct + +// GlobalHashable_TypeID is the unique identifier for the type GlobalHashable. +const GlobalHashable_TypeID = 0xea0b3688577e30b4 + +func NewGlobalHashable(s *capnp.Segment) (GlobalHashable, error) { + st, err := capnp.NewStruct(s, capnp.ObjectSize{DataSize: 8, PointerCount: 7}) + return GlobalHashable(st), err +} + +func NewRootGlobalHashable(s *capnp.Segment) (GlobalHashable, error) { + st, err := capnp.NewRootStruct(s, capnp.ObjectSize{DataSize: 8, PointerCount: 7}) + return GlobalHashable(st), err +} + +func ReadRootGlobalHashable(msg *capnp.Message) (GlobalHashable, error) { + root, err := msg.Root() + return GlobalHashable(root.Struct()), err +} + +func (s GlobalHashable) String() string { + str, _ := text.Marshal(0xea0b3688577e30b4, capnp.Struct(s)) + return str +} + +func (s GlobalHashable) EncodeAsPtr(seg *capnp.Segment) capnp.Ptr { + return capnp.Struct(s).EncodeAsPtr(seg) +} + +func (GlobalHashable) DecodeFromPtr(p capnp.Ptr) GlobalHashable { + return GlobalHashable(capnp.Struct{}.DecodeFromPtr(p)) +} + +func (s GlobalHashable) ToPtr() capnp.Ptr { + return capnp.Struct(s).ToPtr() +} +func (s GlobalHashable) IsValid() bool { + return capnp.Struct(s).IsValid() +} + +func (s GlobalHashable) Message() *capnp.Message { + return capnp.Struct(s).Message() +} + +func (s GlobalHashable) Segment() *capnp.Segment { + return capnp.Struct(s).Segment() +} +func (s GlobalHashable) GlobalCacheKey() (string, error) { + p, err := capnp.Struct(s).Ptr(0) + return p.Text(), err +} + +func (s GlobalHashable) HasGlobalCacheKey() bool { + return capnp.Struct(s).HasPtr(0) +} + +func (s GlobalHashable) GlobalCacheKeyBytes() ([]byte, error) { + p, err := capnp.Struct(s).Ptr(0) + return p.TextBytes(), err +} + +func (s GlobalHashable) SetGlobalCacheKey(v string) error { + return capnp.Struct(s).SetText(0, v) +} + +func (s GlobalHashable) GlobalFileHashMap() (GlobalHashable_Entry_List, error) { + p, err := capnp.Struct(s).Ptr(1) + return GlobalHashable_Entry_List(p.List()), err +} + +func (s GlobalHashable) HasGlobalFileHashMap() bool { + return capnp.Struct(s).HasPtr(1) +} + +func (s GlobalHashable) SetGlobalFileHashMap(v GlobalHashable_Entry_List) error { + return capnp.Struct(s).SetPtr(1, v.ToPtr()) +} + +// NewGlobalFileHashMap sets the globalFileHashMap field to a newly +// allocated GlobalHashable_Entry_List, preferring placement in s's segment. +func (s GlobalHashable) NewGlobalFileHashMap(n int32) (GlobalHashable_Entry_List, error) { + l, err := NewGlobalHashable_Entry_List(capnp.Struct(s).Segment(), n) + if err != nil { + return GlobalHashable_Entry_List{}, err + } + err = capnp.Struct(s).SetPtr(1, l.ToPtr()) + return l, err +} +func (s GlobalHashable) RootExternalDepsHash() (string, error) { + p, err := capnp.Struct(s).Ptr(2) + return p.Text(), err +} + +func (s GlobalHashable) HasRootExternalDepsHash() bool { + return capnp.Struct(s).HasPtr(2) +} + +func (s GlobalHashable) RootExternalDepsHashBytes() ([]byte, error) { + p, err := capnp.Struct(s).Ptr(2) + return p.TextBytes(), err +} + +func (s GlobalHashable) SetRootExternalDepsHash(v string) error { + return capnp.Struct(s).SetText(2, v) +} + +func (s GlobalHashable) Env() (capnp.TextList, error) { + p, err := capnp.Struct(s).Ptr(3) + return capnp.TextList(p.List()), err +} + +func (s GlobalHashable) HasEnv() bool { + return capnp.Struct(s).HasPtr(3) +} + +func (s GlobalHashable) SetEnv(v capnp.TextList) error { + return capnp.Struct(s).SetPtr(3, v.ToPtr()) +} + +// NewEnv sets the env field to a newly +// allocated capnp.TextList, preferring placement in s's segment. +func (s GlobalHashable) NewEnv(n int32) (capnp.TextList, error) { + l, err := capnp.NewTextList(capnp.Struct(s).Segment(), n) + if err != nil { + return capnp.TextList{}, err + } + err = capnp.Struct(s).SetPtr(3, l.ToPtr()) + return l, err +} +func (s GlobalHashable) ResolvedEnvVars() (capnp.TextList, error) { + p, err := capnp.Struct(s).Ptr(4) + return capnp.TextList(p.List()), err +} + +func (s GlobalHashable) HasResolvedEnvVars() bool { + return capnp.Struct(s).HasPtr(4) +} + +func (s GlobalHashable) SetResolvedEnvVars(v capnp.TextList) error { + return capnp.Struct(s).SetPtr(4, v.ToPtr()) +} + +// NewResolvedEnvVars sets the resolvedEnvVars field to a newly +// allocated capnp.TextList, preferring placement in s's segment. +func (s GlobalHashable) NewResolvedEnvVars(n int32) (capnp.TextList, error) { + l, err := capnp.NewTextList(capnp.Struct(s).Segment(), n) + if err != nil { + return capnp.TextList{}, err + } + err = capnp.Struct(s).SetPtr(4, l.ToPtr()) + return l, err +} +func (s GlobalHashable) PassThroughEnv() (capnp.TextList, error) { + p, err := capnp.Struct(s).Ptr(5) + return capnp.TextList(p.List()), err +} + +func (s GlobalHashable) HasPassThroughEnv() bool { + return capnp.Struct(s).HasPtr(5) +} + +func (s GlobalHashable) SetPassThroughEnv(v capnp.TextList) error { + return capnp.Struct(s).SetPtr(5, v.ToPtr()) +} + +// NewPassThroughEnv sets the passThroughEnv field to a newly +// allocated capnp.TextList, preferring placement in s's segment. +func (s GlobalHashable) NewPassThroughEnv(n int32) (capnp.TextList, error) { + l, err := capnp.NewTextList(capnp.Struct(s).Segment(), n) + if err != nil { + return capnp.TextList{}, err + } + err = capnp.Struct(s).SetPtr(5, l.ToPtr()) + return l, err +} +func (s GlobalHashable) EnvMode() GlobalHashable_EnvMode { + return GlobalHashable_EnvMode(capnp.Struct(s).Uint16(0)) +} + +func (s GlobalHashable) SetEnvMode(v GlobalHashable_EnvMode) { + capnp.Struct(s).SetUint16(0, uint16(v)) +} + +func (s GlobalHashable) FrameworkInference() bool { + return capnp.Struct(s).Bit(16) +} + +func (s GlobalHashable) SetFrameworkInference(v bool) { + capnp.Struct(s).SetBit(16, v) +} + +func (s GlobalHashable) DotEnv() (capnp.TextList, error) { + p, err := capnp.Struct(s).Ptr(6) + return capnp.TextList(p.List()), err +} + +func (s GlobalHashable) HasDotEnv() bool { + return capnp.Struct(s).HasPtr(6) +} + +func (s GlobalHashable) SetDotEnv(v capnp.TextList) error { + return capnp.Struct(s).SetPtr(6, v.ToPtr()) +} + +// NewDotEnv sets the dotEnv field to a newly +// allocated capnp.TextList, preferring placement in s's segment. +func (s GlobalHashable) NewDotEnv(n int32) (capnp.TextList, error) { + l, err := capnp.NewTextList(capnp.Struct(s).Segment(), n) + if err != nil { + return capnp.TextList{}, err + } + err = capnp.Struct(s).SetPtr(6, l.ToPtr()) + return l, err +} + +// GlobalHashable_List is a list of GlobalHashable. +type GlobalHashable_List = capnp.StructList[GlobalHashable] + +// NewGlobalHashable creates a new list of GlobalHashable. +func NewGlobalHashable_List(s *capnp.Segment, sz int32) (GlobalHashable_List, error) { + l, err := capnp.NewCompositeList(s, capnp.ObjectSize{DataSize: 8, PointerCount: 7}, sz) + return capnp.StructList[GlobalHashable](l), err +} + +// GlobalHashable_Future is a wrapper for a GlobalHashable promised by a client call. +type GlobalHashable_Future struct{ *capnp.Future } + +func (f GlobalHashable_Future) Struct() (GlobalHashable, error) { + p, err := f.Future.Ptr() + return GlobalHashable(p.Struct()), err +} + +type GlobalHashable_EnvMode uint16 + +// GlobalHashable_EnvMode_TypeID is the unique identifier for the type GlobalHashable_EnvMode. +const GlobalHashable_EnvMode_TypeID = 0xab4200df8263c5d4 + +// Values of GlobalHashable_EnvMode. +const ( + GlobalHashable_EnvMode_infer GlobalHashable_EnvMode = 0 + GlobalHashable_EnvMode_loose GlobalHashable_EnvMode = 1 + GlobalHashable_EnvMode_strict GlobalHashable_EnvMode = 2 +) + +// String returns the enum's constant name. +func (c GlobalHashable_EnvMode) String() string { + switch c { + case GlobalHashable_EnvMode_infer: + return "infer" + case GlobalHashable_EnvMode_loose: + return "loose" + case GlobalHashable_EnvMode_strict: + return "strict" + + default: + return "" + } +} + +// GlobalHashable_EnvModeFromString returns the enum value with a name, +// or the zero value if there's no such value. +func GlobalHashable_EnvModeFromString(c string) GlobalHashable_EnvMode { + switch c { + case "infer": + return GlobalHashable_EnvMode_infer + case "loose": + return GlobalHashable_EnvMode_loose + case "strict": + return GlobalHashable_EnvMode_strict + + default: + return 0 + } +} + +type GlobalHashable_EnvMode_List = capnp.EnumList[GlobalHashable_EnvMode] + +func NewGlobalHashable_EnvMode_List(s *capnp.Segment, sz int32) (GlobalHashable_EnvMode_List, error) { + return capnp.NewEnumList[GlobalHashable_EnvMode](s, sz) +} + +type GlobalHashable_Entry capnp.Struct + +// GlobalHashable_Entry_TypeID is the unique identifier for the type GlobalHashable_Entry. +const GlobalHashable_Entry_TypeID = 0xdd6c3d394436cf49 + +func NewGlobalHashable_Entry(s *capnp.Segment) (GlobalHashable_Entry, error) { + st, err := capnp.NewStruct(s, capnp.ObjectSize{DataSize: 0, PointerCount: 2}) + return GlobalHashable_Entry(st), err +} + +func NewRootGlobalHashable_Entry(s *capnp.Segment) (GlobalHashable_Entry, error) { + st, err := capnp.NewRootStruct(s, capnp.ObjectSize{DataSize: 0, PointerCount: 2}) + return GlobalHashable_Entry(st), err +} + +func ReadRootGlobalHashable_Entry(msg *capnp.Message) (GlobalHashable_Entry, error) { + root, err := msg.Root() + return GlobalHashable_Entry(root.Struct()), err +} + +func (s GlobalHashable_Entry) String() string { + str, _ := text.Marshal(0xdd6c3d394436cf49, capnp.Struct(s)) + return str +} + +func (s GlobalHashable_Entry) EncodeAsPtr(seg *capnp.Segment) capnp.Ptr { + return capnp.Struct(s).EncodeAsPtr(seg) +} + +func (GlobalHashable_Entry) DecodeFromPtr(p capnp.Ptr) GlobalHashable_Entry { + return GlobalHashable_Entry(capnp.Struct{}.DecodeFromPtr(p)) +} + +func (s GlobalHashable_Entry) ToPtr() capnp.Ptr { + return capnp.Struct(s).ToPtr() +} +func (s GlobalHashable_Entry) IsValid() bool { + return capnp.Struct(s).IsValid() +} + +func (s GlobalHashable_Entry) Message() *capnp.Message { + return capnp.Struct(s).Message() +} + +func (s GlobalHashable_Entry) Segment() *capnp.Segment { + return capnp.Struct(s).Segment() +} +func (s GlobalHashable_Entry) Key() (string, error) { + p, err := capnp.Struct(s).Ptr(0) + return p.Text(), err +} + +func (s GlobalHashable_Entry) HasKey() bool { + return capnp.Struct(s).HasPtr(0) +} + +func (s GlobalHashable_Entry) KeyBytes() ([]byte, error) { + p, err := capnp.Struct(s).Ptr(0) + return p.TextBytes(), err +} + +func (s GlobalHashable_Entry) SetKey(v string) error { + return capnp.Struct(s).SetText(0, v) +} + +func (s GlobalHashable_Entry) Value() (string, error) { + p, err := capnp.Struct(s).Ptr(1) + return p.Text(), err +} + +func (s GlobalHashable_Entry) HasValue() bool { + return capnp.Struct(s).HasPtr(1) +} + +func (s GlobalHashable_Entry) ValueBytes() ([]byte, error) { + p, err := capnp.Struct(s).Ptr(1) + return p.TextBytes(), err +} + +func (s GlobalHashable_Entry) SetValue(v string) error { + return capnp.Struct(s).SetText(1, v) +} + +// GlobalHashable_Entry_List is a list of GlobalHashable_Entry. +type GlobalHashable_Entry_List = capnp.StructList[GlobalHashable_Entry] + +// NewGlobalHashable_Entry creates a new list of GlobalHashable_Entry. +func NewGlobalHashable_Entry_List(s *capnp.Segment, sz int32) (GlobalHashable_Entry_List, error) { + l, err := capnp.NewCompositeList(s, capnp.ObjectSize{DataSize: 0, PointerCount: 2}, sz) + return capnp.StructList[GlobalHashable_Entry](l), err +} + +// GlobalHashable_Entry_Future is a wrapper for a GlobalHashable_Entry promised by a client call. +type GlobalHashable_Entry_Future struct{ *capnp.Future } + +func (f GlobalHashable_Entry_Future) Struct() (GlobalHashable_Entry, error) { + p, err := f.Future.Ptr() + return GlobalHashable_Entry(p.Struct()), err +} + +type LockFilePackages capnp.Struct + +// LockFilePackages_TypeID is the unique identifier for the type LockFilePackages. +const LockFilePackages_TypeID = 0xb470b49a14912305 + +func NewLockFilePackages(s *capnp.Segment) (LockFilePackages, error) { + st, err := capnp.NewStruct(s, capnp.ObjectSize{DataSize: 0, PointerCount: 1}) + return LockFilePackages(st), err +} + +func NewRootLockFilePackages(s *capnp.Segment) (LockFilePackages, error) { + st, err := capnp.NewRootStruct(s, capnp.ObjectSize{DataSize: 0, PointerCount: 1}) + return LockFilePackages(st), err +} + +func ReadRootLockFilePackages(msg *capnp.Message) (LockFilePackages, error) { + root, err := msg.Root() + return LockFilePackages(root.Struct()), err +} + +func (s LockFilePackages) String() string { + str, _ := text.Marshal(0xb470b49a14912305, capnp.Struct(s)) + return str +} + +func (s LockFilePackages) EncodeAsPtr(seg *capnp.Segment) capnp.Ptr { + return capnp.Struct(s).EncodeAsPtr(seg) +} + +func (LockFilePackages) DecodeFromPtr(p capnp.Ptr) LockFilePackages { + return LockFilePackages(capnp.Struct{}.DecodeFromPtr(p)) +} + +func (s LockFilePackages) ToPtr() capnp.Ptr { + return capnp.Struct(s).ToPtr() +} +func (s LockFilePackages) IsValid() bool { + return capnp.Struct(s).IsValid() +} + +func (s LockFilePackages) Message() *capnp.Message { + return capnp.Struct(s).Message() +} + +func (s LockFilePackages) Segment() *capnp.Segment { + return capnp.Struct(s).Segment() +} +func (s LockFilePackages) Packages() (Package_List, error) { + p, err := capnp.Struct(s).Ptr(0) + return Package_List(p.List()), err +} + +func (s LockFilePackages) HasPackages() bool { + return capnp.Struct(s).HasPtr(0) +} + +func (s LockFilePackages) SetPackages(v Package_List) error { + return capnp.Struct(s).SetPtr(0, v.ToPtr()) +} + +// NewPackages sets the packages field to a newly +// allocated Package_List, preferring placement in s's segment. +func (s LockFilePackages) NewPackages(n int32) (Package_List, error) { + l, err := NewPackage_List(capnp.Struct(s).Segment(), n) + if err != nil { + return Package_List{}, err + } + err = capnp.Struct(s).SetPtr(0, l.ToPtr()) + return l, err +} + +// LockFilePackages_List is a list of LockFilePackages. +type LockFilePackages_List = capnp.StructList[LockFilePackages] + +// NewLockFilePackages creates a new list of LockFilePackages. +func NewLockFilePackages_List(s *capnp.Segment, sz int32) (LockFilePackages_List, error) { + l, err := capnp.NewCompositeList(s, capnp.ObjectSize{DataSize: 0, PointerCount: 1}, sz) + return capnp.StructList[LockFilePackages](l), err +} + +// LockFilePackages_Future is a wrapper for a LockFilePackages promised by a client call. +type LockFilePackages_Future struct{ *capnp.Future } + +func (f LockFilePackages_Future) Struct() (LockFilePackages, error) { + p, err := f.Future.Ptr() + return LockFilePackages(p.Struct()), err +} + +type Package capnp.Struct + +// Package_TypeID is the unique identifier for the type Package. +const Package_TypeID = 0xc2d08935698f1b78 + +func NewPackage(s *capnp.Segment) (Package, error) { + st, err := capnp.NewStruct(s, capnp.ObjectSize{DataSize: 8, PointerCount: 2}) + return Package(st), err +} + +func NewRootPackage(s *capnp.Segment) (Package, error) { + st, err := capnp.NewRootStruct(s, capnp.ObjectSize{DataSize: 8, PointerCount: 2}) + return Package(st), err +} + +func ReadRootPackage(msg *capnp.Message) (Package, error) { + root, err := msg.Root() + return Package(root.Struct()), err +} + +func (s Package) String() string { + str, _ := text.Marshal(0xc2d08935698f1b78, capnp.Struct(s)) + return str +} + +func (s Package) EncodeAsPtr(seg *capnp.Segment) capnp.Ptr { + return capnp.Struct(s).EncodeAsPtr(seg) +} + +func (Package) DecodeFromPtr(p capnp.Ptr) Package { + return Package(capnp.Struct{}.DecodeFromPtr(p)) +} + +func (s Package) ToPtr() capnp.Ptr { + return capnp.Struct(s).ToPtr() +} +func (s Package) IsValid() bool { + return capnp.Struct(s).IsValid() +} + +func (s Package) Message() *capnp.Message { + return capnp.Struct(s).Message() +} + +func (s Package) Segment() *capnp.Segment { + return capnp.Struct(s).Segment() +} +func (s Package) Key() (string, error) { + p, err := capnp.Struct(s).Ptr(0) + return p.Text(), err +} + +func (s Package) HasKey() bool { + return capnp.Struct(s).HasPtr(0) +} + +func (s Package) KeyBytes() ([]byte, error) { + p, err := capnp.Struct(s).Ptr(0) + return p.TextBytes(), err +} + +func (s Package) SetKey(v string) error { + return capnp.Struct(s).SetText(0, v) +} + +func (s Package) Version() (string, error) { + p, err := capnp.Struct(s).Ptr(1) + return p.Text(), err +} + +func (s Package) HasVersion() bool { + return capnp.Struct(s).HasPtr(1) +} + +func (s Package) VersionBytes() ([]byte, error) { + p, err := capnp.Struct(s).Ptr(1) + return p.TextBytes(), err +} + +func (s Package) SetVersion(v string) error { + return capnp.Struct(s).SetText(1, v) +} + +func (s Package) Found() bool { + return capnp.Struct(s).Bit(0) +} + +func (s Package) SetFound(v bool) { + capnp.Struct(s).SetBit(0, v) +} + +// Package_List is a list of Package. +type Package_List = capnp.StructList[Package] + +// NewPackage creates a new list of Package. +func NewPackage_List(s *capnp.Segment, sz int32) (Package_List, error) { + l, err := capnp.NewCompositeList(s, capnp.ObjectSize{DataSize: 8, PointerCount: 2}, sz) + return capnp.StructList[Package](l), err +} + +// Package_Future is a wrapper for a Package promised by a client call. +type Package_Future struct{ *capnp.Future } + +func (f Package_Future) Struct() (Package, error) { + p, err := f.Future.Ptr() + return Package(p.Struct()), err +} + +type FileHashes capnp.Struct + +// FileHashes_TypeID is the unique identifier for the type FileHashes. +const FileHashes_TypeID = 0xed110dc172c21b8f + +func NewFileHashes(s *capnp.Segment) (FileHashes, error) { + st, err := capnp.NewStruct(s, capnp.ObjectSize{DataSize: 0, PointerCount: 1}) + return FileHashes(st), err +} + +func NewRootFileHashes(s *capnp.Segment) (FileHashes, error) { + st, err := capnp.NewRootStruct(s, capnp.ObjectSize{DataSize: 0, PointerCount: 1}) + return FileHashes(st), err +} + +func ReadRootFileHashes(msg *capnp.Message) (FileHashes, error) { + root, err := msg.Root() + return FileHashes(root.Struct()), err +} + +func (s FileHashes) String() string { + str, _ := text.Marshal(0xed110dc172c21b8f, capnp.Struct(s)) + return str +} + +func (s FileHashes) EncodeAsPtr(seg *capnp.Segment) capnp.Ptr { + return capnp.Struct(s).EncodeAsPtr(seg) +} + +func (FileHashes) DecodeFromPtr(p capnp.Ptr) FileHashes { + return FileHashes(capnp.Struct{}.DecodeFromPtr(p)) +} + +func (s FileHashes) ToPtr() capnp.Ptr { + return capnp.Struct(s).ToPtr() +} +func (s FileHashes) IsValid() bool { + return capnp.Struct(s).IsValid() +} + +func (s FileHashes) Message() *capnp.Message { + return capnp.Struct(s).Message() +} + +func (s FileHashes) Segment() *capnp.Segment { + return capnp.Struct(s).Segment() +} +func (s FileHashes) FileHashes() (FileHashes_Entry_List, error) { + p, err := capnp.Struct(s).Ptr(0) + return FileHashes_Entry_List(p.List()), err +} + +func (s FileHashes) HasFileHashes() bool { + return capnp.Struct(s).HasPtr(0) +} + +func (s FileHashes) SetFileHashes(v FileHashes_Entry_List) error { + return capnp.Struct(s).SetPtr(0, v.ToPtr()) +} + +// NewFileHashes sets the fileHashes field to a newly +// allocated FileHashes_Entry_List, preferring placement in s's segment. +func (s FileHashes) NewFileHashes(n int32) (FileHashes_Entry_List, error) { + l, err := NewFileHashes_Entry_List(capnp.Struct(s).Segment(), n) + if err != nil { + return FileHashes_Entry_List{}, err + } + err = capnp.Struct(s).SetPtr(0, l.ToPtr()) + return l, err +} + +// FileHashes_List is a list of FileHashes. +type FileHashes_List = capnp.StructList[FileHashes] + +// NewFileHashes creates a new list of FileHashes. +func NewFileHashes_List(s *capnp.Segment, sz int32) (FileHashes_List, error) { + l, err := capnp.NewCompositeList(s, capnp.ObjectSize{DataSize: 0, PointerCount: 1}, sz) + return capnp.StructList[FileHashes](l), err +} + +// FileHashes_Future is a wrapper for a FileHashes promised by a client call. +type FileHashes_Future struct{ *capnp.Future } + +func (f FileHashes_Future) Struct() (FileHashes, error) { + p, err := f.Future.Ptr() + return FileHashes(p.Struct()), err +} + +type FileHashes_Entry capnp.Struct + +// FileHashes_Entry_TypeID is the unique identifier for the type FileHashes_Entry. +const FileHashes_Entry_TypeID = 0x8932f7433db89d99 + +func NewFileHashes_Entry(s *capnp.Segment) (FileHashes_Entry, error) { + st, err := capnp.NewStruct(s, capnp.ObjectSize{DataSize: 0, PointerCount: 2}) + return FileHashes_Entry(st), err +} + +func NewRootFileHashes_Entry(s *capnp.Segment) (FileHashes_Entry, error) { + st, err := capnp.NewRootStruct(s, capnp.ObjectSize{DataSize: 0, PointerCount: 2}) + return FileHashes_Entry(st), err +} + +func ReadRootFileHashes_Entry(msg *capnp.Message) (FileHashes_Entry, error) { + root, err := msg.Root() + return FileHashes_Entry(root.Struct()), err +} + +func (s FileHashes_Entry) String() string { + str, _ := text.Marshal(0x8932f7433db89d99, capnp.Struct(s)) + return str +} + +func (s FileHashes_Entry) EncodeAsPtr(seg *capnp.Segment) capnp.Ptr { + return capnp.Struct(s).EncodeAsPtr(seg) +} + +func (FileHashes_Entry) DecodeFromPtr(p capnp.Ptr) FileHashes_Entry { + return FileHashes_Entry(capnp.Struct{}.DecodeFromPtr(p)) +} + +func (s FileHashes_Entry) ToPtr() capnp.Ptr { + return capnp.Struct(s).ToPtr() +} +func (s FileHashes_Entry) IsValid() bool { + return capnp.Struct(s).IsValid() +} + +func (s FileHashes_Entry) Message() *capnp.Message { + return capnp.Struct(s).Message() +} + +func (s FileHashes_Entry) Segment() *capnp.Segment { + return capnp.Struct(s).Segment() +} +func (s FileHashes_Entry) Key() (string, error) { + p, err := capnp.Struct(s).Ptr(0) + return p.Text(), err +} + +func (s FileHashes_Entry) HasKey() bool { + return capnp.Struct(s).HasPtr(0) +} + +func (s FileHashes_Entry) KeyBytes() ([]byte, error) { + p, err := capnp.Struct(s).Ptr(0) + return p.TextBytes(), err +} + +func (s FileHashes_Entry) SetKey(v string) error { + return capnp.Struct(s).SetText(0, v) +} + +func (s FileHashes_Entry) Value() (string, error) { + p, err := capnp.Struct(s).Ptr(1) + return p.Text(), err +} + +func (s FileHashes_Entry) HasValue() bool { + return capnp.Struct(s).HasPtr(1) +} + +func (s FileHashes_Entry) ValueBytes() ([]byte, error) { + p, err := capnp.Struct(s).Ptr(1) + return p.TextBytes(), err +} + +func (s FileHashes_Entry) SetValue(v string) error { + return capnp.Struct(s).SetText(1, v) +} + +// FileHashes_Entry_List is a list of FileHashes_Entry. +type FileHashes_Entry_List = capnp.StructList[FileHashes_Entry] + +// NewFileHashes_Entry creates a new list of FileHashes_Entry. +func NewFileHashes_Entry_List(s *capnp.Segment, sz int32) (FileHashes_Entry_List, error) { + l, err := capnp.NewCompositeList(s, capnp.ObjectSize{DataSize: 0, PointerCount: 2}, sz) + return capnp.StructList[FileHashes_Entry](l), err +} + +// FileHashes_Entry_Future is a wrapper for a FileHashes_Entry promised by a client call. +type FileHashes_Entry_Future struct{ *capnp.Future } + +func (f FileHashes_Entry_Future) Struct() (FileHashes_Entry, error) { + p, err := f.Future.Ptr() + return FileHashes_Entry(p.Struct()), err +} + +const schema_e1dde60149aeb063 = "x\xda\xacV]l\x14U\x14\xfe\xce\xbd\xb3\xdd\xedv" + + "\xebv3\xa3\xa8\x95\xa0\x88\x11L \xa5E\x94&X" + + "(]l\x15\xa4\xe3\xa2\x86\x06\x1e\x86\xedmw\xed:" + + "\xb3\xce\xec\x96\x96\x07Q\xf4\x01\x88\x86`xP\x84D" + + "\x09&F\xe2\xcf\x03&hbBI\xfabb\xc4\x04" + + "bbB\x1a\x125\x88\x90\xe8\x03\xca\x03\xc9\x983\xfb" + + "7m\x11\x1f\xf4\xa9\xd3o\xbe\xf9\xce\xb9\xe7~\xe7\x9c" + + "\xedxB\xae\xd3V\xb6\xfe\xa0A\x98\x8fG\x9a\xfcw" + + "\x8f\x9d^\xbb\xe1\xaf\xce\xfdH- \xff`\xfbYw" + + "\xaa5u\x0d\x11\x11\x05tS\\\xd1w\x04O\xdb\xc4" + + ".\x90\x7f\xd7{\x7f.[x\xe0\xcc[H\xdd#\xfc" + + "\xc9\x9f\xae?\xf3\xdb\xd1\xdf/\x01\xd4\xf5\x85\x88\x93>" + + "\x1d0\xa7\xc4c\xa0\x99\xf3\xd3\xd9\xbd3\xbd'S\xed" + + "\xc2?\xd5\xf1\xca\x0b\xfbV\xb7\\a\xde\xb4\xb8\x97\xf4" + + "\x0b\x01\xef{\xb1\x05\xe4G\x1eI\xe6\xa0 \x12Fp\x9e" + + "\xcd\\\xea~I\xe6\xd6\xd9\xa5\xde3\xae\\/\xef\xd8" + + "\xf5\xd2\x8f8e{\x98\x08\x82(\x94\x82\xa8\x95~K" + + "\xb9T,\x97<\xcc\xb9\xdd\xa1\xeaE\xf6\x85\xd2X?" + + "T\xcdm\xbb ?og\x0be/\xef@\xda^\xed" + + "\xc4\x1c\x92\xcf\xa9&\xfe\xf9\xdd\xedo\xad\xe4N\x02\xff" + + "\xbf\xd1\xc4\\\xa3\x01\xa6F\xe1\xd1C\xbd{\xaa\xde3" + + "W\xd5B\xeb;h\x08\xc8l'I\x99\x1c5\xa2\xeb" + + "\x8a>\x0629\xc6\xdf`\\T\xeeD\x7f-\xe0\xbf" + + "\xca\xf8\x9b\x8cKi\x90\x04\xf4\xfd\xb4\x13\xc8\xecc\xfc" + + "0\xe3\x9af\x90\x06\xe8\x87\xe8\x00\x909\xcc\xf8\xfb\x8c" + + "G\"\x06E\x00\xfd\x18=\x02d\xdea\xfc\x04\xe3M" + + "M\x065\x01\xfa\x07\xd4\x0bd\x8e2\xfe\x11\xe3\xd1\xa8" + + "\x11\xf4\xf1\x87\xf4\"\x909\xc1\xf8\x19\xc6c1\x83b" + + "<\x94h1\x909\xcd\xf8y\xc6\x9b\x9b\x0dj\xe6)" + + "I{\x81\xcc9\xc6\xaf2\x1e\x8f\x1b\x14\x07\xf4_\x83" + + "\xba\x9b\xf1Ua\xff\xae\x0c|" + + "\xd4\xc1\xf8\xa6\xb0\x7f\x07h7\x90\xe9g|\x98\x04Q" + + "\xd5\xbeV`\xdfF;E\xdb*\xf6Ut\xa4\xd6N" + + "\xa5\xc0\xbeM\x15\xfb\xbeL\xdd@\xa6\xc0\xf8>\xaa\x1b" + + "l\x83\x85\x9elN=\xddh\xfa\xea\x8b\x8dy\xaal" + + "\xac\xcd\x16\x15\x1bC\xb8^\xa4\xea\x10v\x1d\xa7\x94\x9e" + + "()b\x17\xb1\x89\x92\xfcMM\xeb\xbf\x18\xc0AO" + + "y4w;\x0f\xd4.\xaf\xe2\x00\x7f\xc4\xb5^R\xbb" + + "\x1c\x97\xc6\x06x\x15)[fUmR\xff\x8b=\xa8" + + "\xb6\xa2{*;:\x18g\x8d_]\xd4Y\xf5Ah" + + "]\x0d\x85\xd6\xd5Hu\xb9C6\x9a\xb1\xad\xf1}\xa5" + + "T\x7f\x07\x00\x00\xff\xffy\xdeB\xa6" + +func RegisterSchema(reg *schemas.Registry) { + reg.Register(&schemas.Schema{ + String: schema_e1dde60149aeb063, + Nodes: []uint64{ + 0x8932f7433db89d99, + 0x8dc08a1d29f69b16, + 0xab4200df8263c5d4, + 0xb470b49a14912305, + 0xc2d08935698f1b78, + 0xd58300fce8aba267, + 0xdd6c3d394436cf49, + 0xe1f09ceb4ef5e479, + 0xea0b3688577e30b4, + 0xed110dc172c21b8f, + }, + Compressed: true, + }) +} diff --git a/cli/internal/fs/hash/capnp_test.go b/cli/internal/fs/hash/capnp_test.go new file mode 100644 index 0000000000000..768bf239b8dc2 --- /dev/null +++ b/cli/internal/fs/hash/capnp_test.go @@ -0,0 +1,176 @@ +package hash + +import ( + "testing" + + "github.com/stretchr/testify/assert" + "github.com/vercel/turbo/cli/internal/env" + "github.com/vercel/turbo/cli/internal/lockfile" + "github.com/vercel/turbo/cli/internal/turbopath" + "github.com/vercel/turbo/cli/internal/util" +) + +// Code generated by capnpc-go. DO NOT EDIT. + +func Test_CapnpHash(t *testing.T) { + taskHashable := TaskHashable{ + GlobalHash: "global_hash", + TaskDependencyHashes: []string{"task_dependency_hash"}, + PackageDir: turbopath.AnchoredUnixPath("package_dir"), + HashOfFiles: "hash_of_files", + ExternalDepsHash: "external_deps_hash", + Task: "task", + Outputs: TaskOutputs{ + Inclusions: []string{"inclusions"}, + Exclusions: []string{"exclusions"}, + }, + PassThruArgs: []string{"pass_thru_args"}, + Env: []string{"env"}, + ResolvedEnvVars: env.EnvironmentVariablePairs{}, + PassThroughEnv: []string{"pass_thru_env"}, + EnvMode: util.Loose, + DotEnv: []turbopath.AnchoredUnixPath{"dotenv"}, + } + + hash, err := HashTaskHashable(&taskHashable) + if err != nil { + t.Fatal(err) + } + + assert.Equal(t, "ff765ee2f83bc034", hash) +} + +func Test_CapnpHashGlobal(t *testing.T) { + globalHashable := GlobalHashable{ + GlobalCacheKey: "global_cache_key", + GlobalFileHashMap: map[turbopath.AnchoredUnixPath]string{ + turbopath.AnchoredUnixPath("global_file_hash_map"): "global_file_hash_map", + }, + RootExternalDepsHash: "root_external_deps_hash", + Env: []string{"env"}, + ResolvedEnvVars: env.EnvironmentVariablePairs{}, + PassThroughEnv: []string{"pass_through_env"}, + EnvMode: util.Infer, + FrameworkInference: true, + + DotEnv: []turbopath.AnchoredUnixPath{"dotenv"}, + } + + hash, err := HashGlobalHashable(&globalHashable) + if err != nil { + t.Fatal(err) + } + + assert.Equal(t, "1d13a81d4c129bed", hash) +} + +func Test_LockfilePackagesEmpty(t *testing.T) { + packages := []lockfile.Package{} + + hash, err := HashLockfilePackages(packages) + if err != nil { + t.Fatal(err) + } + + assert.Equal(t, "459c029558afe716", hash) +} + +func Test_LockfilePackagesNonEmpty(t *testing.T) { + packages := []lockfile.Package{ + { + Key: "key", + Version: "version", + Found: false, + }, + } + + hash, err := HashLockfilePackages(packages) + if err != nil { + t.Fatal(err) + } + + assert.Equal(t, "9e60782f386d8ff1", hash) +} + +func Test_CapnpLockfilePackages_InOrder(t *testing.T) { + packages := []lockfile.Package{ + { + Key: "key", + Version: "version", + Found: false, + }, + { + Key: "zey", + Version: "version", + Found: false, + }, + } + + hash, err := HashLockfilePackages(packages) + if err != nil { + t.Fatal(err) + } + + assert.Equal(t, "765a46fa6c11f363", hash) +} + +func Test_CapnpLockfilePackages_OutOfOrder(t *testing.T) { + packages := []lockfile.Package{ + { + Key: "zey", + Version: "version", + Found: false, + }, + { + Key: "key", + Version: "version", + Found: false, + }, + } + + hash, err := HashLockfilePackages(packages) + if err != nil { + t.Fatal(err) + } + + assert.Equal(t, "1f5d2d372b4398db", hash) +} + +func Test_CapnpFileHashes_Empty(t *testing.T) { + fileHashes := map[turbopath.AnchoredUnixPath]string{} + + hash, err := HashFileHashes(fileHashes) + if err != nil { + t.Fatal(err) + } + + assert.Equal(t, "459c029558afe716", hash) +} + +func Test_CapnpFileHashes_NonEmpty(t *testing.T) { + fileHashes := map[turbopath.AnchoredUnixPath]string{ + turbopath.AnchoredUnixPath("a"): "b", + turbopath.AnchoredUnixPath("c"): "d", + } + + hash, err := HashFileHashes(fileHashes) + if err != nil { + t.Fatal(err) + } + + assert.Equal(t, "c9301c0bf1899c07", hash) +} + +func Test_CapnpFileHashes_OrderResistant(t *testing.T) { + fileHashes := map[turbopath.AnchoredUnixPath]string{ + turbopath.AnchoredUnixPath("c"): "d", + turbopath.AnchoredUnixPath("a"): "b", + } + + hash, err := HashFileHashes(fileHashes) + if err != nil { + t.Fatal(err) + } + + assert.Equal(t, "c9301c0bf1899c07", hash) +} diff --git a/cli/internal/fs/hash_test.go b/cli/internal/fs/hash_test.go index e1ca04286e1f9..f8f24b4b9625f 100644 --- a/cli/internal/fs/hash_test.go +++ b/cli/internal/fs/hash_test.go @@ -3,6 +3,7 @@ package fs import ( "testing" + "github.com/vercel/turbo/cli/internal/fs/hash" "gotest.tools/v3/assert" ) @@ -14,7 +15,7 @@ func Test_HashObjectStability(t *testing.T) { obj interface{} } type complexStruct struct { - nested TaskOutputs + nested hash.TaskOutputs foo string bar []string } @@ -22,7 +23,7 @@ func Test_HashObjectStability(t *testing.T) { testCases := []TestCase{ { name: "task object", - obj: TaskOutputs{ + obj: hash.TaskOutputs{ Inclusions: []string{"foo", "bar"}, Exclusions: []string{"baz"}, }, @@ -30,7 +31,7 @@ func Test_HashObjectStability(t *testing.T) { { name: "complex struct", obj: complexStruct{ - nested: TaskOutputs{ + nested: hash.TaskOutputs{ Exclusions: []string{"bar", "baz"}, Inclusions: []string{"foo"}, }, diff --git a/cli/internal/fs/package_json_test.go b/cli/internal/fs/package_json_test.go index 246e3cbfd7be2..e40649f498922 100644 --- a/cli/internal/fs/package_json_test.go +++ b/cli/internal/fs/package_json_test.go @@ -164,7 +164,7 @@ func Test_SetExternalDepsWithEmptySet(t *testing.T) { assert.NilError(t, err) assert.Assert(t, pkg.TransitiveDeps != nil) assert.Equal(t, len(pkg.TransitiveDeps), 0) - assert.DeepEqual(t, pkg.ExternalDepsHash, "ccab0b28617f1f56") + assert.DeepEqual(t, pkg.ExternalDepsHash, "459c029558afe716") } // Asserts that the data section of two PackageJSON structs are equal diff --git a/cli/internal/fs/turbo_json.go b/cli/internal/fs/turbo_json.go index fc029da2a437a..911ee2ddb6a46 100644 --- a/cli/internal/fs/turbo_json.go +++ b/cli/internal/fs/turbo_json.go @@ -12,6 +12,7 @@ import ( "github.com/muhammadmuzzammil1998/jsonc" "github.com/pkg/errors" + "github.com/vercel/turbo/cli/internal/fs/hash" "github.com/vercel/turbo/cli/internal/turbopath" "github.com/vercel/turbo/cli/internal/util" ) @@ -119,7 +120,7 @@ type rawTask struct { // stream for calculating the global hash. We want to exclude experimental fields here // because we don't want experimental fields to be part of the global hash. type taskDefinitionHashable struct { - Outputs TaskOutputs + Outputs hash.TaskOutputs Cache bool TopologicalDependencies []string TaskDependencies []string @@ -156,7 +157,7 @@ type BookkeepingTaskDefinition struct { // TaskDefinition is a representation of the configFile pipeline for further computation. type TaskDefinition struct { - Outputs TaskOutputs + Outputs hash.TaskOutputs Cache bool // TopologicalDependencies are tasks from package dependencies. @@ -292,18 +293,6 @@ func (tj *TurboJSON) Validate(validations []TurboJSONValidation) []error { return allErrors } -// TaskOutputs represents the patterns for including and excluding files from outputs -type TaskOutputs struct { - Inclusions []string - Exclusions []string -} - -// Sort contents of task outputs -func (to *TaskOutputs) Sort() { - sort.Strings(to.Inclusions) - sort.Strings(to.Exclusions) -} - // readTurboConfig reads turbo.json from a provided path func readTurboConfig(turboJSONPath turbopath.AbsoluteSystemPath) (*TurboJSON, error) { // If the configFile exists, use that @@ -503,7 +492,7 @@ func (btd *BookkeepingTaskDefinition) UnmarshalJSON(data []byte) error { } } - btd.TaskDefinition.Outputs = TaskOutputs{ + btd.TaskDefinition.Outputs = hash.TaskOutputs{ Inclusions: inclusions, Exclusions: exclusions, } @@ -769,7 +758,7 @@ func (tj *TurboJSON) MarshalJSON() ([]byte, error) { } func makeRawTask( - outputs TaskOutputs, + outputs hash.TaskOutputs, shouldCache bool, topologicalDependencies []string, taskDependencies []string, diff --git a/cli/internal/fs/turbo_json_test.go b/cli/internal/fs/turbo_json_test.go index cf8a987015f1a..dd2f4cb401cd7 100644 --- a/cli/internal/fs/turbo_json_test.go +++ b/cli/internal/fs/turbo_json_test.go @@ -8,6 +8,7 @@ import ( "testing" "github.com/stretchr/testify/assert" + "github.com/vercel/turbo/cli/internal/fs/hash" "github.com/vercel/turbo/cli/internal/turbopath" "github.com/vercel/turbo/cli/internal/util" "gotest.tools/v3/assert/cmp" @@ -45,7 +46,7 @@ func Test_ReadTurboConfigDotEnvUndefined(t *testing.T) { experimentalFields: util.SetFromStrings([]string{}), experimental: taskDefinitionExperiments{}, TaskDefinition: taskDefinitionHashable{ - Outputs: TaskOutputs{}, + Outputs: hash.TaskOutputs{}, Cache: true, TopologicalDependencies: []string{}, TaskDependencies: []string{}, @@ -80,7 +81,7 @@ func Test_ReadTurboConfigDotEnvNull(t *testing.T) { experimentalFields: util.SetFromStrings([]string{}), experimental: taskDefinitionExperiments{}, TaskDefinition: taskDefinitionHashable{ - Outputs: TaskOutputs{}, + Outputs: hash.TaskOutputs{}, Cache: true, TopologicalDependencies: []string{}, TaskDependencies: []string{}, @@ -112,7 +113,7 @@ func Test_ReadTurboConfigDotEnvEmpty(t *testing.T) { experimentalFields: util.SetFromStrings([]string{}), experimental: taskDefinitionExperiments{}, TaskDefinition: taskDefinitionHashable{ - Outputs: TaskOutputs{}, + Outputs: hash.TaskOutputs{}, Cache: true, TopologicalDependencies: []string{}, TaskDependencies: []string{}, @@ -145,7 +146,7 @@ func Test_ReadTurboConfigDotEnvPopulated(t *testing.T) { experimentalFields: util.SetFromStrings([]string{}), experimental: taskDefinitionExperiments{}, TaskDefinition: taskDefinitionHashable{ - Outputs: TaskOutputs{}, + Outputs: hash.TaskOutputs{}, Cache: true, TopologicalDependencies: []string{}, TaskDependencies: []string{}, @@ -181,7 +182,7 @@ func Test_ReadTurboConfigPassThroughEnvUndefined(t *testing.T) { experimentalFields: util.SetFromStrings([]string{}), experimental: taskDefinitionExperiments{}, TaskDefinition: taskDefinitionHashable{ - Outputs: TaskOutputs{}, + Outputs: hash.TaskOutputs{}, Cache: true, TopologicalDependencies: []string{}, TaskDependencies: []string{}, @@ -217,7 +218,7 @@ func Test_ReadTurboConfigPassThroughEnvNull(t *testing.T) { experimentalFields: util.SetFromStrings([]string{}), experimental: taskDefinitionExperiments{}, TaskDefinition: taskDefinitionHashable{ - Outputs: TaskOutputs{}, + Outputs: hash.TaskOutputs{}, Cache: true, TopologicalDependencies: []string{}, TaskDependencies: []string{}, @@ -250,7 +251,7 @@ func Test_ReadTurboConfigPassThroughEnvEmpty(t *testing.T) { experimentalFields: util.SetFromStrings([]string{}), experimental: taskDefinitionExperiments{}, TaskDefinition: taskDefinitionHashable{ - Outputs: TaskOutputs{}, + Outputs: hash.TaskOutputs{}, Cache: true, TopologicalDependencies: []string{}, TaskDependencies: []string{}, @@ -283,7 +284,7 @@ func Test_ReadTurboConfigPassThroughEnvPopulated(t *testing.T) { experimentalFields: util.SetFromStrings([]string{}), experimental: taskDefinitionExperiments{}, TaskDefinition: taskDefinitionHashable{ - Outputs: TaskOutputs{}, + Outputs: hash.TaskOutputs{}, Cache: true, TopologicalDependencies: []string{}, TaskDependencies: []string{}, @@ -317,7 +318,7 @@ func Test_ReadTurboConfig(t *testing.T) { experimentalFields: util.SetFromStrings([]string{}), experimental: taskDefinitionExperiments{}, TaskDefinition: taskDefinitionHashable{ - Outputs: TaskOutputs{Inclusions: []string{".next/**", "dist/**"}, Exclusions: []string{"dist/assets/**"}}, + Outputs: hash.TaskOutputs{Inclusions: []string{".next/**", "dist/**"}, Exclusions: []string{"dist/assets/**"}}, Cache: true, TopologicalDependencies: []string{"build"}, TaskDependencies: []string{}, @@ -331,7 +332,7 @@ func Test_ReadTurboConfig(t *testing.T) { experimentalFields: util.SetFromStrings([]string{}), experimental: taskDefinitionExperiments{}, TaskDefinition: taskDefinitionHashable{ - Outputs: TaskOutputs{}, + Outputs: hash.TaskOutputs{}, Cache: true, TopologicalDependencies: []string{}, TaskDependencies: []string{}, @@ -345,7 +346,7 @@ func Test_ReadTurboConfig(t *testing.T) { experimentalFields: util.SetFromStrings([]string{}), experimental: taskDefinitionExperiments{}, TaskDefinition: taskDefinitionHashable{ - Outputs: TaskOutputs{}, + Outputs: hash.TaskOutputs{}, Cache: false, TopologicalDependencies: []string{}, TaskDependencies: []string{}, @@ -359,7 +360,7 @@ func Test_ReadTurboConfig(t *testing.T) { experimentalFields: util.SetFromStrings([]string{}), experimental: taskDefinitionExperiments{}, TaskDefinition: taskDefinitionHashable{ - Outputs: TaskOutputs{Inclusions: []string{"dist/**"}}, + Outputs: hash.TaskOutputs{Inclusions: []string{"dist/**"}}, Cache: false, TopologicalDependencies: []string{"build", "publish"}, TaskDependencies: []string{"admin#lint", "build"}, @@ -412,7 +413,7 @@ func Test_LoadTurboConfig_BothCorrectAndLegacy(t *testing.T) { experimentalFields: util.SetFromStrings([]string{}), experimental: taskDefinitionExperiments{}, TaskDefinition: taskDefinitionHashable{ - Outputs: TaskOutputs{Inclusions: []string{".next/**", "dist/**"}, Exclusions: []string{"dist/assets/**"}}, + Outputs: hash.TaskOutputs{Inclusions: []string{".next/**", "dist/**"}, Exclusions: []string{"dist/assets/**"}}, Cache: true, TopologicalDependencies: []string{"build"}, TaskDependencies: []string{}, @@ -480,12 +481,12 @@ func Test_ReadTurboConfig_EnvDeclarations(t *testing.T) { func Test_TaskOutputsSort(t *testing.T) { inclusions := []string{"foo/**", "bar"} exclusions := []string{"special-file", ".hidden/**"} - taskOutputs := TaskOutputs{Inclusions: inclusions, Exclusions: exclusions} + taskOutputs := hash.TaskOutputs{Inclusions: inclusions, Exclusions: exclusions} taskOutputs.Sort() assertIsSorted(t, taskOutputs.Inclusions, "Inclusions") assertIsSorted(t, taskOutputs.Exclusions, "Exclusions") - assert.True(t, cmp.DeepEqual(taskOutputs, TaskOutputs{Inclusions: []string{"bar", "foo/**"}, Exclusions: []string{".hidden/**", "special-file"}})().Success()) + assert.True(t, cmp.DeepEqual(taskOutputs, hash.TaskOutputs{Inclusions: []string{"bar", "foo/**"}, Exclusions: []string{".hidden/**", "special-file"}})().Success()) } // Helpers diff --git a/cli/internal/globwatcher/globwatcher.go b/cli/internal/globwatcher/globwatcher.go index 9226cfaeed983..4463c93f0c5c3 100644 --- a/cli/internal/globwatcher/globwatcher.go +++ b/cli/internal/globwatcher/globwatcher.go @@ -9,7 +9,7 @@ import ( "github.com/hashicorp/go-hclog" "github.com/vercel/turbo/cli/internal/doublestar" "github.com/vercel/turbo/cli/internal/filewatcher" - "github.com/vercel/turbo/cli/internal/fs" + "github.com/vercel/turbo/cli/internal/fs/hash" "github.com/vercel/turbo/cli/internal/turbopath" "github.com/vercel/turbo/cli/internal/util" ) @@ -63,7 +63,7 @@ func (g *GlobWatcher) isClosed() bool { // WatchGlobs registers the given set of globs to be watched for changes and grouped // under the given hash. This method pairs with GetChangedGlobs to determine which globs // out of a set of candidates have changed since WatchGlobs was called for the same hash. -func (g *GlobWatcher) WatchGlobs(hash string, globsToWatch fs.TaskOutputs) error { +func (g *GlobWatcher) WatchGlobs(hash string, globsToWatch hash.TaskOutputs) error { if g.isClosed() { return ErrClosed } diff --git a/cli/internal/globwatcher/globwatcher_test.go b/cli/internal/globwatcher/globwatcher_test.go index 6fb89a76c8d71..e93327fc1c2b0 100644 --- a/cli/internal/globwatcher/globwatcher_test.go +++ b/cli/internal/globwatcher/globwatcher_test.go @@ -6,6 +6,7 @@ import ( "github.com/hashicorp/go-hclog" "github.com/vercel/turbo/cli/internal/filewatcher" "github.com/vercel/turbo/cli/internal/fs" + "github.com/vercel/turbo/cli/internal/fs/hash" "github.com/vercel/turbo/cli/internal/turbopath" "gotest.tools/v3/assert" ) @@ -66,7 +67,7 @@ func TestTrackOutputs(t *testing.T) { globWatcher := New(logger, repoRoot, _noopCookieWaiter) - globs := fs.TaskOutputs{ + globs := hash.TaskOutputs{ Inclusions: []string{ "my-pkg/dist/**", "my-pkg/.next/**", @@ -142,18 +143,18 @@ func TestTrackMultipleHashes(t *testing.T) { globWatcher := New(logger, repoRoot, _noopCookieWaiter) - globs := fs.TaskOutputs{ + globs := hash.TaskOutputs{ Inclusions: []string{ "my-pkg/dist/**", "my-pkg/.next/**", }, } - hash := "the-hash" - err := globWatcher.WatchGlobs(hash, globs) + hashToWatch := "the-hash" + err := globWatcher.WatchGlobs(hashToWatch, globs) assert.NilError(t, err, "WatchGlobs") - secondGlobs := fs.TaskOutputs{ + secondGlobs := hash.TaskOutputs{ Inclusions: []string{ "my-pkg/.next/**", }, @@ -164,7 +165,7 @@ func TestTrackMultipleHashes(t *testing.T) { err = globWatcher.WatchGlobs(secondHash, secondGlobs) assert.NilError(t, err, "WatchGlobs") - changed, err := globWatcher.GetChangedGlobs(hash, globs.Inclusions) + changed, err := globWatcher.GetChangedGlobs(hashToWatch, globs.Inclusions) assert.NilError(t, err, "GetChangedGlobs") assert.Equal(t, 0, len(changed), "Expected no changed paths") @@ -178,7 +179,7 @@ func TestTrackMultipleHashes(t *testing.T) { Path: repoRoot.UntypedJoin("my-pkg", ".next", "cache", "foo"), }) - changed, err = globWatcher.GetChangedGlobs(hash, globs.Inclusions) + changed, err = globWatcher.GetChangedGlobs(hashToWatch, globs.Inclusions) assert.NilError(t, err, "GetChangedGlobs") assert.Equal(t, 1, len(changed), "Expected one changed path remaining") @@ -206,7 +207,7 @@ func TestWatchSingleFile(t *testing.T) { //watcher := newTestWatcher() globWatcher := New(logger, repoRoot, _noopCookieWaiter) - globs := fs.TaskOutputs{ + globs := hash.TaskOutputs{ Inclusions: []string{"my-pkg/.next/next-file"}, Exclusions: []string{}, } diff --git a/cli/internal/lockfile/lockfile.go b/cli/internal/lockfile/lockfile.go index 9d8a2143ca82e..846814124d02e 100644 --- a/cli/internal/lockfile/lockfile.go +++ b/cli/internal/lockfile/lockfile.go @@ -31,11 +31,11 @@ func IsNil(l Lockfile) bool { // Package Structure representing a possible Pack type Package struct { // Key used to lookup a package in the lockfile - Key string + Key string `json:"key"` // The resolved version of a package as it appears in the lockfile - Version string + Version string `json:"version"` // Set to true iff Key and Version are set - Found bool + Found bool `json:"-"` } // ByKey sort package structures by key @@ -50,7 +50,11 @@ func (p ByKey) Swap(i, j int) { } func (p ByKey) Less(i, j int) bool { - return p[i].Key+p[i].Version < p[j].Key+p[j].Version + if p[i].Key == p[j].Key { + return p[i].Version < p[j].Version + } + + return p[i].Key < p[j].Key } var _ (sort.Interface) = (*ByKey)(nil) diff --git a/cli/internal/nodes/packagetask.go b/cli/internal/nodes/packagetask.go index e9654b82f4d69..39b5b66384046 100644 --- a/cli/internal/nodes/packagetask.go +++ b/cli/internal/nodes/packagetask.go @@ -5,6 +5,7 @@ import ( "fmt" "github.com/vercel/turbo/cli/internal/fs" + "github.com/vercel/turbo/cli/internal/fs/hash" "github.com/vercel/turbo/cli/internal/util" ) @@ -34,11 +35,11 @@ func (pt *PackageTask) OutputPrefix(isSinglePackage bool) string { // HashableOutputs returns the package-relative globs for files to be considered outputs // of this task -func (pt *PackageTask) HashableOutputs() fs.TaskOutputs { +func (pt *PackageTask) HashableOutputs() hash.TaskOutputs { inclusionOutputs := []string{fmt.Sprintf(".turbo/turbo-%v.log", pt.Task)} inclusionOutputs = append(inclusionOutputs, pt.TaskDefinition.Outputs.Inclusions...) - hashable := fs.TaskOutputs{ + hashable := hash.TaskOutputs{ Inclusions: inclusionOutputs, Exclusions: pt.TaskDefinition.Outputs.Exclusions, } diff --git a/cli/internal/run/global_hash.go b/cli/internal/run/global_hash.go index 55173796f0523..f1a6be7186816 100644 --- a/cli/internal/run/global_hash.go +++ b/cli/internal/run/global_hash.go @@ -7,6 +7,7 @@ import ( "github.com/hashicorp/go-hclog" "github.com/vercel/turbo/cli/internal/env" "github.com/vercel/turbo/cli/internal/fs" + "github.com/vercel/turbo/cli/internal/fs/hash" "github.com/vercel/turbo/cli/internal/globby" "github.com/vercel/turbo/cli/internal/hashing" "github.com/vercel/turbo/cli/internal/lockfile" @@ -39,7 +40,7 @@ type GlobalHashableInputs struct { // It's used for the situations where we have an `EnvMode` specified // as that is not compatible with existing global hashes. func calculateGlobalHash(full GlobalHashableInputs) (string, error) { - return fs.HashGlobal(fs.GlobalHashable{ + return fs.HashGlobal(hash.GlobalHashable{ GlobalCacheKey: full.globalCacheKey, GlobalFileHashMap: full.globalFileHashMap, RootExternalDepsHash: full.rootExternalDepsHash, diff --git a/cli/internal/run/real_run.go b/cli/internal/run/real_run.go index 4c9e1d89363bf..de5d6f69b2e4a 100644 --- a/cli/internal/run/real_run.go +++ b/cli/internal/run/real_run.go @@ -8,6 +8,7 @@ import ( "log" "os" "os/exec" + "reflect" "strings" "sync" "time" @@ -31,6 +32,7 @@ import ( "github.com/vercel/turbo/cli/internal/spinner" "github.com/vercel/turbo/cli/internal/taskhash" "github.com/vercel/turbo/cli/internal/turbopath" + "github.com/vercel/turbo/cli/internal/turbostate" "github.com/vercel/turbo/cli/internal/ui" "github.com/vercel/turbo/cli/internal/util" ) @@ -136,6 +138,7 @@ func RealRun( runSummary runsummary.Meta, packageManager *packagemanager.PackageManager, processes *process.Manager, + executionState *turbostate.ExecutionState, ) error { singlePackage := rs.Opts.runOpts.SinglePackage @@ -279,6 +282,26 @@ func RealRun( logWaitGroup.Wait() } + if executionState.TaskHashTracker != nil { + expectedTaskHashes := taskHashTracker.GetTaskHashes() + // If we have errors, not all the Go hashes may be calculated. + // We just check the ones that have been calculated + if len(errs) > 0 { + for task, expectedHash := range expectedTaskHashes { + hash, ok := executionState.TaskHashTracker.PackageTaskHashes[task] + if !ok { + return fmt.Errorf("task %s not found in Rust hash tracker", task) + } + if hash != expectedHash { + return fmt.Errorf("task %s hash differs between Rust and Go: rust %s go %s", task, hash, expectedHash) + } + } + } else if !reflect.DeepEqual(executionState.TaskHashTracker.PackageTaskHashes, expectedTaskHashes) { + return fmt.Errorf("task hashes differ between Rust and Go: rust %v go %v", executionState.TaskHashTracker.PackageTaskHashes, expectedTaskHashes) + } + base.Logger.Debug("task hashes match") + } + // Track if we saw any child with a non-zero exit code exitCode := 0 exitCodeErr := &process.ChildExit{} diff --git a/cli/internal/run/run.go b/cli/internal/run/run.go index 1ca8cfdb56184..f2e24bf9469a2 100644 --- a/cli/internal/run/run.go +++ b/cli/internal/run/run.go @@ -166,6 +166,7 @@ func (r *run) run(ctx gocontext.Context, targets []string, executionState *turbo } else { pkgDepGraph, err = context.BuildPackageGraph(r.base.RepoRoot, rootPackageJSON, executionState.PackageManager) } + if err != nil { var warnings *context.Warnings if errors.As(err, &warnings) { @@ -266,6 +267,13 @@ func (r *run) run(ctx gocontext.Context, targets []string, executionState *turbo if globalHash, err := calculateGlobalHashFromHashableInputs(globalHashInputs); err == nil { r.base.Logger.Debug("global hash", "value", globalHash) + if executionState.GlobalHash != nil { + if *executionState.GlobalHash != globalHash { + return fmt.Errorf("global hash differs between Rust and Go: rust %v go %v", executionState.GlobalHash, globalHash) + } + r.base.Logger.Debug("global hash matches between Rust and Go") + } + g.GlobalHash = globalHash } else { return fmt.Errorf("failed to calculate global hash: %v", err) @@ -294,7 +302,7 @@ func (r *run) run(ctx gocontext.Context, targets []string, executionState *turbo g.RootNode, g.GlobalHash, envAtExecutionStart, - // TODO(mehulkar): remove g,Pipeline, because we need to get task definitions from CompleteGaph instead + // TODO(mehulkar): remove g.Pipeline, because we need to get task definitions from CompleteGraph instead g.Pipeline, ) @@ -422,6 +430,7 @@ func (r *run) run(ctx gocontext.Context, targets []string, executionState *turbo // Extra arg only for regular runs, dry-run doesn't get this packageManager, r.processes, + executionState, ) } diff --git a/cli/internal/runcache/output_watcher.go b/cli/internal/runcache/output_watcher.go index d9f744b523c66..0eddce998d1a5 100644 --- a/cli/internal/runcache/output_watcher.go +++ b/cli/internal/runcache/output_watcher.go @@ -3,7 +3,7 @@ package runcache import ( "context" - "github.com/vercel/turbo/cli/internal/fs" + "github.com/vercel/turbo/cli/internal/fs/hash" ) // OutputWatcher instances are responsible for tracking changes to task outputs @@ -11,7 +11,7 @@ type OutputWatcher interface { // GetChangedOutputs returns which of the given globs have changed since the specified hash was last run GetChangedOutputs(ctx context.Context, hash string, repoRelativeOutputGlobs []string) ([]string, int, error) // NotifyOutputsWritten tells the watcher that the given globs have been cached with the specified hash - NotifyOutputsWritten(ctx context.Context, hash string, repoRelativeOutputGlobs fs.TaskOutputs, timeSaved int) error + NotifyOutputsWritten(ctx context.Context, hash string, repoRelativeOutputGlobs hash.TaskOutputs, timeSaved int) error } // NoOpOutputWatcher implements OutputWatcher, but always considers every glob to have changed @@ -27,6 +27,6 @@ func (NoOpOutputWatcher) GetChangedOutputs(_ context.Context, _ string, repoRela // NotifyOutputsWritten implements OutputWatcher.NotifyOutputsWritten. // Since this is a no-op watcher, consider all globs to have changed -func (NoOpOutputWatcher) NotifyOutputsWritten(_ context.Context, _ string, _ fs.TaskOutputs, _ int) error { +func (NoOpOutputWatcher) NotifyOutputsWritten(_ context.Context, _ string, _ hash.TaskOutputs, _ int) error { return nil } diff --git a/cli/internal/runcache/runcache.go b/cli/internal/runcache/runcache.go index f5eb914809d2d..2abf4f8af4600 100644 --- a/cli/internal/runcache/runcache.go +++ b/cli/internal/runcache/runcache.go @@ -15,6 +15,7 @@ import ( "github.com/vercel/turbo/cli/internal/cache" "github.com/vercel/turbo/cli/internal/colorcache" "github.com/vercel/turbo/cli/internal/fs" + "github.com/vercel/turbo/cli/internal/fs/hash" "github.com/vercel/turbo/cli/internal/globby" "github.com/vercel/turbo/cli/internal/logstreamer" "github.com/vercel/turbo/cli/internal/nodes" @@ -99,7 +100,7 @@ func New(cache cache.Cache, repoRoot turbopath.AbsoluteSystemPath, opts Opts, co type TaskCache struct { ExpandedOutputs []turbopath.AnchoredSystemPath rc *RunCache - repoRelativeGlobs fs.TaskOutputs + repoRelativeGlobs hash.TaskOutputs hash string pt *nodes.PackageTask taskOutputMode util.TaskOutputMode @@ -301,10 +302,10 @@ func (tc *TaskCache) SaveOutputs(ctx context.Context, logger hclog.Logger, termi // TaskCache returns a TaskCache instance, providing an interface to the underlying cache specific // to this run and the given PackageTask -func (rc *RunCache) TaskCache(pt *nodes.PackageTask, hash string) TaskCache { +func (rc *RunCache) TaskCache(pt *nodes.PackageTask, packageTaskHash string) TaskCache { logFileName := rc.repoRoot.UntypedJoin(pt.LogFile) hashableOutputs := pt.HashableOutputs() - repoRelativeGlobs := fs.TaskOutputs{ + repoRelativeGlobs := hash.TaskOutputs{ Inclusions: make([]string, len(hashableOutputs.Inclusions)), Exclusions: make([]string, len(hashableOutputs.Exclusions)), } @@ -325,7 +326,7 @@ func (rc *RunCache) TaskCache(pt *nodes.PackageTask, hash string) TaskCache { ExpandedOutputs: []turbopath.AnchoredSystemPath{}, rc: rc, repoRelativeGlobs: repoRelativeGlobs, - hash: hash, + hash: packageTaskHash, pt: pt, taskOutputMode: taskOutputMode, cachingDisabled: !pt.TaskDefinition.Cache, diff --git a/cli/internal/server/server.go b/cli/internal/server/server.go index c0b56f7b36d0a..4c7c42c8548b6 100644 --- a/cli/internal/server/server.go +++ b/cli/internal/server/server.go @@ -9,6 +9,7 @@ import ( "github.com/pkg/errors" "github.com/vercel/turbo/cli/internal/filewatcher" "github.com/vercel/turbo/cli/internal/fs" + "github.com/vercel/turbo/cli/internal/fs/hash" "github.com/vercel/turbo/cli/internal/globwatcher" "github.com/vercel/turbo/cli/internal/turbodprotocol" "github.com/vercel/turbo/cli/internal/turbopath" @@ -143,7 +144,7 @@ func (s *Server) NotifyOutputsWritten(ctx context.Context, req *turbodprotocol.N s.timeSavedMu.Lock() s.timesSaved[req.Hash] = req.TimeSaved s.timeSavedMu.Unlock() - outputs := fs.TaskOutputs{ + outputs := hash.TaskOutputs{ Inclusions: req.OutputGlobs, Exclusions: req.OutputExclusionGlobs, } diff --git a/cli/internal/taskhash/taskhash.go b/cli/internal/taskhash/taskhash.go index d37d30ea6ba67..d249eedbd09c0 100644 --- a/cli/internal/taskhash/taskhash.go +++ b/cli/internal/taskhash/taskhash.go @@ -12,6 +12,7 @@ import ( "github.com/pyr-sh/dag" "github.com/vercel/turbo/cli/internal/env" "github.com/vercel/turbo/cli/internal/fs" + "github.com/vercel/turbo/cli/internal/fs/hash" "github.com/vercel/turbo/cli/internal/hashing" "github.com/vercel/turbo/cli/internal/inference" "github.com/vercel/turbo/cli/internal/nodes" @@ -33,12 +34,12 @@ type Tracker struct { EnvAtExecutionStart env.EnvironmentVariableMap pipeline fs.Pipeline - packageInputsHashes map[string]string + PackageInputsHashes map[string]string - // packageInputsExpandedHashes is a map of a hashkey to a list of files that are inputs to the task. + // PackageInputsExpandedHashes is a map of a hashkey to a list of files that are inputs to the task. // Writes to this map happen during CalculateFileHash(). Since this happens synchronously // before walking the task graph, it does not need to be protected by a mutex. - packageInputsExpandedHashes map[string]map[turbopath.AnchoredUnixPath]string + PackageInputsExpandedHashes map[string]map[turbopath.AnchoredUnixPath]string // mu is a mutex that we can lock/unlock to read/write from maps // the fields below should be protected by the mutex. @@ -174,8 +175,8 @@ outer: if err != nil { return err } - th.packageInputsHashes = hashes - th.packageInputsExpandedHashes = hashObjects + th.PackageInputsHashes = hashes + th.PackageInputsExpandedHashes = hashObjects return nil } @@ -186,7 +187,7 @@ outer: // hashOfFiles string // externalDepsHash string // task string -// outputs fs.TaskOutputs +// outputs hash.TaskOutputs // passThruArgs []string // env []string // resolvedEnvVars env.EnvironmentVariablePairs @@ -196,7 +197,7 @@ outer: // } // calculateTaskHashFromHashable returns a hash string from the taskHashable -func calculateTaskHashFromHashable(full *fs.TaskHashable) (string, error) { +func calculateTaskHashFromHashable(full *hash.TaskHashable) (string, error) { switch full.EnvMode { case util.Loose: // Remove the passthroughs from hash consideration if we're explicitly loose. @@ -247,7 +248,7 @@ func (th *Tracker) calculateDependencyHashes(dependencySet dag.Set) ([]string, e // that it has previously been called on its task-graph dependencies. File hashes must be calculated // first. func (th *Tracker) CalculateTaskHash(logger hclog.Logger, packageTask *nodes.PackageTask, dependencySet dag.Set, frameworkInference bool, args []string) (string, error) { - hashOfFiles, ok := th.packageInputsHashes[packageTask.TaskID] + hashOfFiles, ok := th.PackageInputsHashes[packageTask.TaskID] if !ok { return "", fmt.Errorf("cannot find package-file hash for %v", packageTask.TaskID) } @@ -299,7 +300,6 @@ func (th *Tracker) CalculateTaskHash(logger hclog.Logger, packageTask *nodes.Pac if err != nil { return "", err } - explicitEnvVarMap.Union(allEnvVarMap) } } else { @@ -329,7 +329,7 @@ func (th *Tracker) CalculateTaskHash(logger hclog.Logger, packageTask *nodes.Pac // log any auto detected env vars logger.Debug(fmt.Sprintf("task hash env vars for %s:%s", packageTask.PackageName, packageTask.Task), "vars", hashableEnvPairs) - hash, err := calculateTaskHashFromHashable(&fs.TaskHashable{ + hash, err := calculateTaskHashFromHashable(&hash.TaskHashable{ GlobalHash: th.globalHash, TaskDependencyHashes: taskDependencyHashes, PackageDir: packageTask.Pkg.Dir.ToUnixPath(), @@ -359,7 +359,7 @@ func (th *Tracker) CalculateTaskHash(logger hclog.Logger, packageTask *nodes.Pac // GetExpandedInputs gets the expanded set of inputs for a given PackageTask func (th *Tracker) GetExpandedInputs(packageTask *nodes.PackageTask) map[turbopath.AnchoredUnixPath]string { - expandedInputs := th.packageInputsExpandedHashes[packageTask.TaskID] + expandedInputs := th.PackageInputsExpandedHashes[packageTask.TaskID] inputsCopy := make(map[turbopath.AnchoredUnixPath]string, len(expandedInputs)) for path, hash := range expandedInputs { @@ -403,6 +403,13 @@ func (th *Tracker) SetExpandedOutputs(taskID string, outputs []turbopath.Anchore th.packageTaskOutputs[taskID] = outputs } +// GetTaskHashes gets the package task hashes +func (th *Tracker) GetTaskHashes() map[string]string { + th.mu.RLock() + defer th.mu.RUnlock() + return th.packageTaskHashes +} + // SetCacheStatus records the task status for the given taskID func (th *Tracker) SetCacheStatus(taskID string, cacheSummary runsummary.TaskCacheSummary) { th.mu.Lock() diff --git a/cli/internal/turbostate/turbostate.go b/cli/internal/turbostate/turbostate.go index 5ac4e8137c4dc..1a814bb94c780 100644 --- a/cli/internal/turbostate/turbostate.go +++ b/cli/internal/turbostate/turbostate.go @@ -91,12 +91,19 @@ type ParsedArgsFromRust struct { Command Command `json:"command"` } +// TaskHashTracker stores the hashes calculated in Rust +type TaskHashTracker struct { + PackageTaskHashes map[string]string `json:"package_task_hashes"` +} + // ExecutionState is the entire state of a turbo execution that is passed from the Rust shim. type ExecutionState struct { APIClientConfig APIClientConfig `json:"api_client_config"` SpacesAPIClientConfig APIClientConfig `json:"spaces_api_client_config"` PackageManager string `json:"package_manager"` CLIArgs ParsedArgsFromRust `json:"cli_args"` + GlobalHash *string `json:"global_hash"` + TaskHashTracker *TaskHashTracker `json:"task_hash_tracker"` } // APIClientConfig holds the authentication and endpoint details for the API client diff --git a/crates/turborepo-lib/Cargo.toml b/crates/turborepo-lib/Cargo.toml index c19e1481016f4..a6eeaa56472f8 100644 --- a/crates/turborepo-lib/Cargo.toml +++ b/crates/turborepo-lib/Cargo.toml @@ -130,5 +130,5 @@ async-io = "1.12.0" winapi = "0.3.9" [build-dependencies] -capnpc = "0.17.2" +capnpc = "0.18.0" tonic-build = "0.8.4" diff --git a/crates/turborepo-lib/src/cli.rs b/crates/turborepo-lib/src/cli.rs index 82be20ce08861..1340ff1cbd013 100644 --- a/crates/turborepo-lib/src/cli.rs +++ b/crates/turborepo-lib/src/cli.rs @@ -4,7 +4,6 @@ use anyhow::{anyhow, Result}; use camino::Utf8PathBuf; use clap::{ArgAction, CommandFactory, Parser, Subcommand, ValueEnum}; use clap_complete::{generate, Shell}; -use itertools::Itertools; use serde::{Deserialize, Serialize}; use tracing::{debug, error}; use turbopath::AbsoluteSystemPathBuf; diff --git a/crates/turborepo-lib/src/execution_state.rs b/crates/turborepo-lib/src/execution_state.rs index 24403268284e7..97e8b760c9b85 100644 --- a/crates/turborepo-lib/src/execution_state.rs +++ b/crates/turborepo-lib/src/execution_state.rs @@ -2,10 +2,12 @@ use serde::Serialize; use tracing::trace; use turborepo_repository::{package_json::PackageJson, package_manager::PackageManager}; -use crate::{cli::Args, commands::CommandBase}; +use crate::{cli::Args, commands::CommandBase, run::Run, task_hash::TaskHashTrackerState}; #[derive(Debug, Serialize)] pub struct ExecutionState<'a> { + global_hash: Option, + task_hash_tracker: Option, pub api_client_config: APIClientConfig<'a>, pub spaces_api_client_config: SpacesAPIClientConfig<'a>, package_manager: PackageManager, @@ -38,8 +40,23 @@ pub struct SpacesAPIClientConfig<'a> { impl<'a> TryFrom<&'a CommandBase> for ExecutionState<'a> { type Error = anyhow::Error; - fn try_from(base: &'a CommandBase) -> Result { + let run = Run::new(base); + + let global_hash; + let task_hash_tracker; + #[cfg(debug_assertions)] + { + let result = run.get_hashes()?; + global_hash = Some(result.0); + task_hash_tracker = Some(result.1); + } + #[cfg(not(debug_assertions))] + { + global_hash = None; + task_hash_tracker = None; + } + let root_package_json = PackageJson::load(&base.repo_root.join_component("package.json")).ok(); @@ -71,6 +88,8 @@ impl<'a> TryFrom<&'a CommandBase> for ExecutionState<'a> { }; Ok(ExecutionState { + global_hash, + task_hash_tracker, api_client_config, spaces_api_client_config, package_manager, diff --git a/crates/turborepo-lib/src/run/mod.rs b/crates/turborepo-lib/src/run/mod.rs index 3fac49336adf2..f5514aa834911 100644 --- a/crates/turborepo-lib/src/run/mod.rs +++ b/crates/turborepo-lib/src/run/mod.rs @@ -39,7 +39,7 @@ use crate::{ summary::{GlobalHashSummary, RunSummary}, }, task_graph::Visitor, - task_hash::PackageInputsHashes, + task_hash::{PackageInputsHashes, TaskHashTrackerState}, }; #[derive(Debug)] @@ -254,7 +254,7 @@ impl<'a> Run<'a> { let workspaces = pkg_dep_graph.workspaces().collect(); let package_inputs_hashes = PackageInputsHashes::calculate_file_hashes( - scm, + &scm, engine.tasks().par_bridge(), workspaces, engine.task_definitions(), @@ -311,6 +311,18 @@ impl<'a> Run<'a> { resolved_pass_through_env_vars, ); + let workspaces = pkg_dep_graph.workspaces().collect(); + + let package_file_hashes = PackageInputsHashes::calculate_file_hashes( + &scm, + engine.tasks().par_bridge(), + workspaces, + engine.task_definitions(), + &self.base.repo_root, + )?; + + debug!("package file hashes: {:?}", package_file_hashes); + let mut run_summary = RunSummary::new( start_at, &self.base.repo_root, @@ -327,4 +339,160 @@ impl<'a> Run<'a> { Ok(exit_code) } + + #[tokio::main] + pub async fn get_hashes(&self) -> Result<(String, TaskHashTrackerState)> { + let env_at_execution_start = EnvironmentVariableMap::infer(); + + let package_json_path = self.base.repo_root.join_component("package.json"); + let root_package_json = + PackageJson::load(&package_json_path).context("failed to read package.json")?; + + let opts = self.opts()?; + + let is_single_package = opts.run_opts.single_package; + + let pkg_dep_graph = PackageGraph::builder(&self.base.repo_root, root_package_json.clone()) + .with_single_package_mode(opts.run_opts.single_package) + .build()?; + + let root_turbo_json = + TurboJson::load(&self.base.repo_root, &root_package_json, is_single_package)?; + + let root_workspace = pkg_dep_graph + .workspace_info(&WorkspaceName::Root) + .expect("must have root workspace"); + + let root_external_dependencies_hash = root_workspace.get_external_deps_hash(); + + let mut global_hash_inputs = get_global_hash_inputs( + !opts.run_opts.single_package, + &root_external_dependencies_hash, + &self.base.repo_root, + pkg_dep_graph.package_manager(), + pkg_dep_graph.lockfile(), + &root_turbo_json.global_deps, + &env_at_execution_start, + &root_turbo_json.global_env, + root_turbo_json.global_pass_through_env.as_deref(), + opts.run_opts.env_mode, + opts.run_opts.framework_inference, + &root_turbo_json.global_dot_env, + )?; + + let scm = SCM::new(&self.base.repo_root); + + let filtered_pkgs = { + let mut filtered_pkgs = scope::resolve_packages( + &opts.scope_opts, + &self.base.repo_root, + &pkg_dep_graph, + &scm, + )?; + + if filtered_pkgs.len() != pkg_dep_graph.len() { + for target in self.targets() { + let task_name = TaskName::from(target.as_str()).into_root_task(); + + if root_turbo_json.pipeline.contains_key(&task_name) { + filtered_pkgs.insert(WorkspaceName::Root); + break; + } + } + } + + filtered_pkgs + }; + + let global_hash = global_hash_inputs.calculate_global_hash_from_inputs(); + + let repo_config = self.base.repo_config()?; + let team_id = repo_config.team_id(); + let team_slug = repo_config.team_slug(); + + let token = self.base.user_config()?.token(); + + let api_auth = team_id.zip(token).map(|(team_id, token)| APIAuth { + team_id: team_id.to_string(), + token: token.to_string(), + team_slug: team_slug.map(|s| s.to_string()), + }); + + let engine = EngineBuilder::new( + &self.base.repo_root, + &pkg_dep_graph, + opts.run_opts.single_package, + ) + .with_root_tasks(root_turbo_json.pipeline.keys().cloned()) + .with_turbo_jsons(Some( + Some((WorkspaceName::Root, root_turbo_json.clone())) + .into_iter() + .collect(), + )) + .with_tasks_only(opts.run_opts.only) + .with_workspaces(filtered_pkgs.into_iter().collect()) + .with_tasks( + opts.run_opts + .tasks + .iter() + .map(|task| TaskName::from(task.as_str()).into_owned()), + ) + .build()?; + + let mut global_env_mode = opts.run_opts.env_mode; + if matches!(global_env_mode, EnvMode::Infer) + && root_turbo_json.global_pass_through_env.is_some() + { + global_env_mode = EnvMode::Strict; + } + + let package_inputs_hashes = PackageInputsHashes::calculate_file_hashes( + &scm, + engine.tasks().par_bridge(), + pkg_dep_graph.workspaces().collect(), + engine.task_definitions(), + &self.base.repo_root, + )?; + + let pkg_dep_graph = Arc::new(pkg_dep_graph); + let engine = Arc::new(engine); + + let async_cache = AsyncCache::new( + &opts.cache_opts, + &self.base.repo_root, + self.base.api_client()?, + api_auth, + )?; + + let color_selector = ColorSelector::default(); + + let runcache = Arc::new(RunCache::new( + async_cache, + &self.base.repo_root, + &opts.runcache_opts, + color_selector, + None, + self.base.ui, + )); + + let visitor = Visitor::new( + pkg_dep_graph.clone(), + runcache, + &opts, + package_inputs_hashes, + &env_at_execution_start, + &global_hash, + global_env_mode, + self.base.ui, + true, + self.processes.clone(), + &self.base.repo_root, + ) + .dry_run(); + + visitor.visit(engine.clone()).await?; + let task_hash_tracker = visitor.into_task_hash_tracker(); + + Ok((global_hash, task_hash_tracker)) + } } diff --git a/crates/turborepo-lib/src/run/task_id.rs b/crates/turborepo-lib/src/run/task_id.rs index 0e5d47496b0cf..67674572453ac 100644 --- a/crates/turborepo-lib/src/run/task_id.rs +++ b/crates/turborepo-lib/src/run/task_id.rs @@ -9,7 +9,7 @@ pub const ROOT_PKG_NAME: &str = "//"; /// A task identifier as it will appear in the task graph #[derive(Debug, Clone, Hash, PartialEq, Eq, PartialOrd, Ord, Serialize)] -#[serde(from = "String")] +#[serde(from = "String", into = "String")] pub struct TaskId<'a> { package: Cow<'a, str>, task: Cow<'a, str>, diff --git a/crates/turborepo-lib/src/task_graph/visitor.rs b/crates/turborepo-lib/src/task_graph/visitor.rs index 27243f2fbd9f1..51d78dc6bb36d 100644 --- a/crates/turborepo-lib/src/task_graph/visitor.rs +++ b/crates/turborepo-lib/src/task_graph/visitor.rs @@ -42,6 +42,7 @@ pub struct Visitor<'a> { ui: UI, manager: ProcessManager, repo_root: &'a AbsoluteSystemPath, + dry: bool, } #[derive(Debug, thiserror::Error)] @@ -101,6 +102,7 @@ impl<'a> Visitor<'a> { ui, manager, repo_root, + dry: false, } } @@ -180,6 +182,10 @@ impl<'a> Visitor<'a> { )?; debug!("task {} hash is {}", info, task_hash); + if self.dry { + callback.send(Ok(())).ok(); + continue; + } let task_cache = self.run_cache @@ -387,6 +393,11 @@ impl<'a> Visitor<'a> { pub fn into_task_hash_tracker(self) -> TaskHashTrackerState { self.task_hasher.into_task_hash_tracker_state() } + + pub fn dry_run(mut self) -> Self { + self.dry = true; + self + } } // A tiny enum that allows us to use the same type for stdout and stderr without diff --git a/crates/turborepo-lib/src/task_hash.rs b/crates/turborepo-lib/src/task_hash.rs index 6c20144f2f41f..b61218ec9dd4c 100644 --- a/crates/turborepo-lib/src/task_hash.rs +++ b/crates/turborepo-lib/src/task_hash.rs @@ -61,7 +61,7 @@ pub struct PackageInputsHashes { impl PackageInputsHashes { pub fn calculate_file_hashes<'a>( - scm: SCM, + scm: &SCM, all_tasks: impl ParallelIterator, workspaces: HashMap<&WorkspaceName, &WorkspaceInfo>, task_definitions: &HashMap, TaskDefinition>, diff --git a/crates/turborepo/src/main.rs b/crates/turborepo/src/main.rs index 347240cdc3cc6..fce2a432937fd 100644 --- a/crates/turborepo/src/main.rs +++ b/crates/turborepo/src/main.rs @@ -68,7 +68,10 @@ fn run_go_binary(execution_state: ExecutionState) -> Result { fn main() -> Result<()> { let exit_code = match turborepo_lib::main() { Payload::Rust(res) => res.unwrap_or(1), - Payload::Go(base) => run_go_binary((&*base).try_into()?)?, + Payload::Go(base) => { + let execution_state = (&*base).try_into()?; + run_go_binary(execution_state)? + } }; process::exit(exit_code) diff --git a/go.work.sum b/go.work.sum new file mode 100644 index 0000000000000..16f6800e88d3c --- /dev/null +++ b/go.work.sum @@ -0,0 +1,144 @@ +cloud.google.com/go v0.99.0 h1:y/cM2iqGgGi5D5DQZl6D9STN/3dR/Vx5Mp8s752oJTY= +cloud.google.com/go/bigquery v1.8.0 h1:PQcPefKFdaIzjQFbiyOgAqyx8q5djaE7x9Sqe712DPA= +cloud.google.com/go/datastore v1.1.0 h1:/May9ojXjRkPBNVrq+oWLqmWCkr4OU5uRY29bu0mRyQ= +cloud.google.com/go/firestore v1.6.1 h1:8rBq3zRjnHx8UtBvaOWqBB1xq9jH6/wltfQLlTMh2Fw= +cloud.google.com/go/pubsub v1.3.1 h1:ukjixP1wl0LpnZ6LWtZJ0mX5tBmjp1f8Sqer8Z2OMUU= +cloud.google.com/go/storage v1.10.0 h1:STgFzyU5/8miMl0//zKh2aQeTyeaUH3WN9bSUiJ09bA= +dmitri.shuralyov.com/gpu/mtl v0.0.0-20190408044501-666a987793e9 h1:VpgP7xuJadIUuKccphEpTJnWhS2jkQyMt6Y7pJCD7fY= +github.com/BurntSushi/toml v0.3.1 h1:WXkYYl6Yr3qBf1K79EBnL4mak0OimBfB0XUf9Vl28OQ= +github.com/BurntSushi/xgb v0.0.0-20160522181843-27f122750802 h1:1BDTz0u9nC3//pOCMdNH+CiXJVYJh5UQNCOBG7jbELc= +github.com/DataDog/datadog-go v3.2.0+incompatible h1:qSG2N4FghB1He/r2mFrWKCaL7dXCilEuNEeAn20fdD4= +github.com/Netflix/go-expect v0.0.0-20220104043353-73e0943537d2 h1:+vx7roKuyA63nhn5WAunQHLTznkw5W8b1Xc0dNjp83s= +github.com/OneOfOne/xxhash v1.2.2 h1:KMrpdQIwFcEqXDklaen+P1axHaj9BSKzvpUUfnHldSE= +github.com/alecthomas/template v0.0.0-20190718012654-fb15b899a751 h1:JYp7IbQjafoB+tBA3gMyHYHrpOtNuDiK/uB5uXxq5wM= +github.com/alecthomas/units v0.0.0-20190717042225-c3de453c63f4 h1:Hs82Z41s6SdL1CELW+XaDYmOH4hkBN4/N9og/AsOv7E= +github.com/antihax/optional v1.0.0 h1:xK2lYat7ZLaVVcIuj82J8kIro4V6kDe0AUDFboUCwcg= +github.com/armon/circbuf v0.0.0-20150827004946-bbbad097214e h1:QEF07wC0T1rKkctt1RINW/+RMTVmiwxETico2l3gxJA= +github.com/armon/go-metrics v0.3.10 h1:FR+drcQStOe+32sYyJYyZ7FIdgoGGBnwLl+flodp8Uo= +github.com/beorn7/perks v1.0.1 h1:VlbKKnNfV8bJzeqoa4cOKqO6bYr3WgKZxO8Z16+hsOM= +github.com/census-instrumentation/opencensus-proto v0.3.0 h1:t/LhUZLVitR1Ow2YOnduCsavhwFUklBMoGVYUCqmCqk= +github.com/cespare/xxhash v1.1.0 h1:a6HrQnmkObjyL+Gs60czilIUGqrzKutQD6XZog3p+ko= +github.com/cespare/xxhash/v2 v2.1.2 h1:YRXhKfTDauu4ajMg1TPgFO5jnlC2HCbmLXMcTG5cbYE= +github.com/chzyer/logex v1.1.10 h1:Swpa1K6QvQznwJRcfTfQJmTE72DqScAa40E+fbHEXEE= +github.com/chzyer/readline v0.0.0-20180603132655-2972be24d48e h1:fY5BOSpyZCqRo5OhCuC+XN+r/bBCmeuuJtjz+bCNIf8= +github.com/chzyer/test v0.0.0-20180213035817-a1ea475d72b1 h1:q763qf9huN11kDQavWsoZXJNW3xEE4JJyHa5Q25/sd8= +github.com/circonus-labs/circonus-gometrics v2.3.1+incompatible h1:C29Ae4G5GtYyYMm1aztcyj/J5ckgJm2zwdDajFbx1NY= +github.com/circonus-labs/circonusllhist v0.1.3 h1:TJH+oke8D16535+jHExHj4nQvzlZrj7ug5D7I/orNUA= +github.com/client9/misspell v0.3.4 h1:ta993UF76GwbvJcIo3Y68y/M3WxlpEHPWIGDkJYwzJI= +github.com/cncf/udpa/go v0.0.0-20210930031921-04548b0d99d4 h1:hzAQntlaYRkVSFEfj9OTWlVV1H155FMD8BTKktLv0QI= +github.com/cncf/xds/go v0.0.0-20211130200136-a8f946100490 h1:KwaoQzs/WeUxxJqiJsZ4euOly1Az/IgZXXSxlD/UBNk= +github.com/coreos/go-semver v0.3.0 h1:wkHLiw0WNATZnSG7epLsujiMCgPAc9xhjJ4tgnAxmfM= +github.com/coreos/go-systemd/v22 v22.3.2 h1:D9/bQk5vlXQFZ6Kwuu6zaiXJ9oTPe68++AzAJc1DzSI= +github.com/cpuguy83/go-md2man/v2 v2.0.1 h1:r/myEWzV9lfsM1tFLgDyu0atFtJ1fXn261LKYj/3DxU= +github.com/creack/pty v1.1.17 h1:QeVUsEDNrLBW4tMgZHvxy18sKtr6VI492kBhUfhDJNI= +github.com/envoyproxy/go-control-plane v0.10.2-0.20220325020618-49ff273808a1 h1:xvqufLtNVwAhN8NMyWklVgxnWohi+wtMGQMhtxexlm0= +github.com/envoyproxy/protoc-gen-validate v0.6.2 h1:JiO+kJTpmYGjEodY7O1Zk8oZcNz1+f30UtwtXoFUPzE= +github.com/ghodss/yaml v1.0.0 h1:wQHKEahhL6wmXdzwWG11gIVCkOv05bNOh+Rxn0yngAk= +github.com/go-gl/glfw v0.0.0-20190409004039-e6da0acd62b1 h1:QbL/5oDUmRBzO9/Z7Seo6zf912W/a6Sr4Eu0G/3Jho0= +github.com/go-gl/glfw/v3.3/glfw v0.0.0-20200222043503-6f7a984d4dc4 h1:WtGNWLvXpe6ZudgnXrq0barxBImvnnJoMEhXAzcbM0I= +github.com/go-kit/kit v0.9.0 h1:wDJmvq38kDhkVxi50ni9ykkdUr1PKgqKOoi01fa0Mdk= +github.com/go-logfmt/logfmt v0.4.0 h1:MP4Eh7ZCb31lleYCFuwm0oe4/YGak+5l1vA2NOE80nA= +github.com/go-stack/stack v1.8.0 h1:5SgMzNM5HxrEjV0ww2lTmX6E2Izsfxas4+YHWRs3Lsk= +github.com/godbus/dbus/v5 v5.0.4 h1:9349emZab16e7zQvpmsbtjc18ykshndd8y2PG3sgJbA= +github.com/gogo/protobuf v1.3.2 h1:Ov1cvc58UF3b5XjBnZv7+opcTcQFZebYjWzi34vdm4Q= +github.com/golang/glog v0.0.0-20160126235308-23def4e6c14b h1:VKtxabqXZkF25pY9ekfRL6a582T4P37/31XEstQ5p58= +github.com/golang/groupcache v0.0.0-20210331224755-41bb18bfe9da h1:oI5xCqsCo564l8iNU+DwB5epxmsaqB+rhGL0m5jtYqE= +github.com/golang/mock v1.6.0 h1:ErTB+efbowRARo13NNdxyJji2egdxLGQhRaY+DUumQc= +github.com/golang/snappy v0.0.3 h1:fHPg5GQYlCeLIPB9BZqMVR5nR9A+IM5zcgeTdjMYmLA= +github.com/google/btree v1.0.0 h1:0udJVsspx3VBr5FwtLhQQtuAsVc79tTq0ocGIPAU6qo= +github.com/google/gofuzz v1.0.0 h1:A8PeW59pxE9IoFRqBp37U+mSNaQoZ46F1f0f863XSXw= +github.com/google/martian v2.1.0+incompatible h1:/CP5g8u/VJHijgedC/Legn3BAbAaWPgecwXBIDzw5no= +github.com/google/martian/v3 v3.2.1 h1:d8MncMlErDFTwQGBK1xhv026j9kqhvw1Qv9IbWT1VLQ= +github.com/google/pprof v0.0.0-20210720184732-4bb14d4b1be1 h1:K6RDEckDVWvDI9JAJYCmNdQXq6neHJOYx3V6jnqNEec= +github.com/google/renameio v0.1.0 h1:GOZbcHa3HfsPKPlmyPyN2KEohoMXOhdMbHrvbpl2QaA= +github.com/googleapis/gax-go/v2 v2.1.1 h1:dp3bWCh+PPO1zjRRiCSczJav13sBvG4UhNyVTa1KqdU= +github.com/grpc-ecosystem/grpc-gateway v1.16.0 h1:gmcG1KaJ57LophUzW0Hy8NmPhnMZb4M0+kPpLofRdBo= +github.com/hashicorp/consul/api v1.11.0 h1:Hw/G8TtRvOElqxVIhBzXciiSTbapq8hZ2XKZsXk5ZCE= +github.com/hashicorp/consul/sdk v0.8.0 h1:OJtKBtEjboEZvG6AOUdh4Z1Zbyu0WcxQ0qatRrZHTVU= +github.com/hashicorp/go-immutable-radix v1.3.1 h1:DKHmCUm2hRBK510BaiZlwvpD40f8bJFeZnpfm2KLowc= +github.com/hashicorp/go-msgpack v0.5.3 h1:zKjpN5BK/P5lMYrLmBHdBULWbJ0XpYR+7NGzqkZzoD4= +github.com/hashicorp/go-rootcerts v1.0.2 h1:jzhAVGtqPKbwpyCPELlgNWhE1znq+qwJtW5Oi2viEzc= +github.com/hashicorp/go-sockaddr v1.0.0 h1:GeH6tui99pF4NJgfnhp+L6+FfobzVW3Ah46sLo0ICXs= +github.com/hashicorp/go-syslog v1.0.0 h1:KaodqZuhUoZereWVIYmpUgZysurB1kBLX2j0MwMrUAE= +github.com/hashicorp/go-uuid v1.0.1 h1:fv1ep09latC32wFoVwnqcnKJGnMSdBanPczbHAYm1BE= +github.com/hashicorp/golang-lru v0.5.4 h1:YDjusn29QI/Das2iO9M0BHnIbxPeyuCHsjMW+lJfyTc= +github.com/hashicorp/hcl v1.0.0 h1:0Anlzjpi4vEasTeNFn2mLJgTSwt0+6sfsiTG8qcWGx4= +github.com/hashicorp/logutils v1.0.0 h1:dLEQVugN8vlakKOUE3ihGLTZJRB4j+M2cdTm/ORI65Y= +github.com/hashicorp/mdns v1.0.4 h1:sY0CMhFmjIPDMlTB+HfymFHCaYLhgifZ0QhjaYKD/UQ= +github.com/hashicorp/memberlist v0.3.0 h1:8+567mCcFDnS5ADl7lrpxPMWiFCElyUEeW0gtj34fMA= +github.com/hashicorp/serf v0.9.6 h1:uuEX1kLR6aoda1TBttmJQKDLZE1Ob7KN0NPdE7EtCDc= +github.com/hinshun/vt10x v0.0.0-20220119200601-820417d04eec h1:qv2VnGeEQHchGaZ/u7lxST/RaJw+cv273q79D81Xbog= +github.com/iancoleman/strcase v0.2.0 h1:05I4QRnGpI0m37iZQRuskXh+w77mr6Z41lwQzuHLwW0= +github.com/ianlancetaylor/demangle v0.0.0-20200824232613-28f6c0f3b639 h1:mV02weKRL81bEnm8A0HT1/CAelMQDBuQIfLw8n+d6xI= +github.com/json-iterator/go v1.1.12 h1:PV8peI4a0ysnczrg+LtxykD8LfKY9ML6u2jnxaEnrnM= +github.com/jstemmer/go-junit-report v0.9.1 h1:6QPYqodiu3GuPL+7mfx+NwDdp2eTkp9IfEUpgAwUN0o= +github.com/julienschmidt/httprouter v1.2.0 h1:TDTW5Yz1mjftljbcKqRcrYhd4XeOoI98t+9HbQbYf7g= +github.com/k0kubun/go-ansi v0.0.0-20180517002512-3bf9e2903213 h1:qGQQKEcAR99REcMpsXCp3lJ03zYT1PkRd3kQGPn9GVg= +github.com/kballard/go-shellquote v0.0.0-20180428030007-95032a82bc51 h1:Z9n2FFNUXsshfwJMBgNA0RU6/i7WVaAegv3PtuIHPMs= +github.com/kisielk/errcheck v1.5.0 h1:e8esj/e4R+SAOwFwN+n3zr0nYeCyeweozKfO23MvHzY= +github.com/kisielk/gotool v1.0.0 h1:AV2c/EiW3KqPNT9ZKl07ehoAGi4C5/01Cfbblndcapg= +github.com/konsorten/go-windows-terminal-sequences v1.0.1 h1:mweAR1A6xJ3oS2pRaGiHgQ4OO8tzTaLawm8vnODuwDk= +github.com/kr/fs v0.1.0 h1:Jskdu9ieNAYnjxsi0LbQp1ulIKZV1LAFgK1tWhpZgl8= +github.com/kr/logfmt v0.0.0-20140226030751-b84e30acd515 h1:T+h1c/A9Gawja4Y9mFVWj2vyii2bbUNDw3kt9VxK2EY= +github.com/kr/pty v1.1.1 h1:VkoXIwSboBpnk99O/KFauAEILuNHv5DVFKZMBN/gUgw= +github.com/kylelemons/godebug v1.1.0 h1:RPNrshWIDI6G2gRW9EHilWtl7Z6Sb1BR0xunSBf0SNc= +github.com/lyft/protoc-gen-star v0.5.3 h1:zSGLzsUew8RT+ZKPHc3jnf8XLaVyHzTcAFBzHtCNR20= +github.com/magiconair/properties v1.8.5 h1:b6kJs+EmPFMYGkow9GiUyCyOvIwYetYJ3fSaWak/Gls= +github.com/matttproud/golang_protobuf_extensions v1.0.1 h1:4hp9jkHxhMHkqkrB3Ix0jegS5sx/RkqARlsWZ6pIwiU= +github.com/mgutz/ansi v0.0.0-20170206155736-9520e82c474b h1:j7+1HpAFS1zy5+Q4qx1fWh90gTKwiN4QCGoY9TWyyO4= +github.com/miekg/dns v1.1.41 h1:WMszZWJG0XmzbK9FEmzH2TVcqYzFesusSIB41b8KHxY= +github.com/mitchellh/go-homedir v1.1.0 h1:lukF9ziXFxDFPkA1vsr5zpc1XuPDn/wFntq5mG+4E0Y= +github.com/mitchellh/go-testing-interface v1.0.0 h1:fzU/JVNcaqHQEcVFAKeR41fkiLdIPrefOvVG1VZ96U0= +github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd h1:TRLaZ9cD/w8PVh93nsPXa1VrQ6jlwL5oN8l14QlcNfg= +github.com/modern-go/reflect2 v1.0.2 h1:xBagoLtFs94CBntxluKeaWgTMpvLxC4ur3nMaC9Gz0M= +github.com/mwitkow/go-conntrack v0.0.0-20161129095857-cc309e4a2223 h1:F9x/1yl3T2AeKLr2AMdilSD8+f9bvMnNN8VS5iDtovc= +github.com/opentracing/opentracing-go v1.1.0 h1:pWlfV3Bxv7k65HYwkikxat0+s3pV4bsqf19k25Ur8rU= +github.com/pascaldekloe/goe v0.1.0 h1:cBOtyMzM9HTpWjXfbbunk26uA6nG3a8n06Wieeh0MwY= +github.com/pelletier/go-toml v1.9.4 h1:tjENF6MfZAg8e4ZmZTeWaWiT2vXtsoO6+iuOjFhECwM= +github.com/pkg/sftp v1.10.1 h1:VasscCm72135zRysgrJDKsntdmPN+OuU3+nnHYA9wyc= +github.com/prometheus/client_golang v1.4.0 h1:YVIb/fVcOTMSqtqZWSKnHpSLBxu8DKgxq8z6RuBZwqI= +github.com/prometheus/client_model v0.2.0 h1:uq5h0d+GuxiXLJLNABMgp2qUWDPiLvgCzz2dUR+/W/M= +github.com/prometheus/common v0.9.1 h1:KOMtN28tlbam3/7ZKEYKHhKoJZYYj3gMH4uc62x7X7U= +github.com/prometheus/procfs v0.0.8 h1:+fpWZdT24pJBiqJdAwYBjPSk+5YmQzYNPYzQsdzLkt8= +github.com/rogpeppe/fastuuid v1.2.0 h1:Ppwyp6VYCF1nvBTXL3trRso7mXMlRrw9ooo375wvi2s= +github.com/russross/blackfriday/v2 v2.1.0 h1:JIOH55/0cWyOuilr9/qlrm0BSXldqnqwMsf35Ld67mk= +github.com/ryanuber/columnize v0.0.0-20160712163229-9b3edd62028f h1:UFr9zpz4xgTnIE5yIMtWAMngCdZ9p/+q6lTbgelo80M= +github.com/sagikazarmark/crypt v0.3.0 h1:TV5DVog+pihN4Rr0rN1IClv4ePpkzdg9sPrw7WDofZ8= +github.com/sean-/seed v0.0.0-20170313163322-e2103e2c3529 h1:nn5Wsu0esKSJiIVhscUtVbo7ada43DJhG55ua/hjS5I= +github.com/sirupsen/logrus v1.4.2 h1:SPIRibHv4MatM3XXNO2BJeFLZwZ2LvZgfQ5+UNI2im4= +github.com/spaolacci/murmur3 v0.0.0-20180118202830-f09979ecbc72 h1:qLC7fQah7D6K1B0ujays3HV9gkFtllcxhzImRR7ArPQ= +github.com/spf13/afero v1.6.0 h1:xoax2sJ2DT8S8xA2paPFjDCScCNeWsg75VG0DLRreiY= +github.com/spf13/jwalterweatherman v1.1.0 h1:ue6voC5bR5F8YxI5S67j9i582FU4Qvo2bmqnqMYADFk= +github.com/spf13/viper v1.10.0 h1:mXH0UwHS4D2HwWZa75im4xIQynLfblmWV7qcWpfv0yk= +github.com/stretchr/objx v0.5.0 h1:1zr/of2m5FGMsad5YfcqgdqdWrIhu+EBEJRhR1U7z/c= +github.com/subosito/gotenv v1.2.0 h1:Slr1R9HxAlEKefgq5jn9U+DnETlIUa6HfgEzj0g5d7s= +github.com/tj/assert v0.0.3 h1:Df/BlaZ20mq6kuai7f5z2TvPFiwC3xaWJSDQNiIS3Rk= +github.com/tv42/httpunix v0.0.0-20150427012821-b75d8614f926 h1:G3dpKMzFDjgEh2q1Z7zUUtKa8ViPtH+ocF0bE0g00O8= +github.com/yuin/goldmark v1.4.13 h1:fVcFKWvrslecOb/tg+Cc05dkeYx540o0FuFt3nUVDoE= +go.etcd.io/etcd/api/v3 v3.5.1 h1:v28cktvBq+7vGyJXF8G+rWJmj+1XUmMtqcLnH8hDocM= +go.etcd.io/etcd/client/pkg/v3 v3.5.1 h1:XIQcHCFSG53bJETYeRJtIxdLv2EWRGxcfzR8lSnTH4E= +go.etcd.io/etcd/client/v2 v2.305.1 h1:vtxYCKWA9x31w0WJj7DdqsHFNjhkigdAnziDtkZb/l4= +go.opencensus.io v0.23.0 h1:gqCw0LfLxScz8irSi8exQc7fyQ0fKQU/qnC/X8+V/1M= +go.opentelemetry.io/proto/otlp v0.7.0 h1:rwOQPCuKAKmwGKq2aVNnYIibI6wnV7EvzgfTCzcdGg8= +go.uber.org/atomic v1.7.0 h1:ADUqmZGgLDDfbSL9ZmPxKTybcoEYHgpYfELNoN+7hsw= +go.uber.org/multierr v1.6.0 h1:y6IPFStTAIT5Ytl7/XYmHvzXQ7S3g/IeZW9hyZ5thw4= +go.uber.org/zap v1.17.0 h1:MTjgFu6ZLKvY6Pvaqk97GlxNBuMpV4Hy/3P6tRGlI2U= +golang.org/x/exp v0.0.0-20230321023759-10a507213a29 h1:ooxPy7fPvB4kwsA2h+iBNHkAbp/4JxTSwCmvdjEYmug= +golang.org/x/image v0.0.0-20190802002840-cff245a6509b h1:+qEpEAPhDZ1o0x3tHzZTQDArnOixOzGD9HUJfcg0mb4= +golang.org/x/lint v0.0.0-20210508222113-6edffad5e616 h1:VLliZ0d+/avPrXXH+OakdXhpJuEoBZuwh1m2j7U6Iug= +golang.org/x/mobile v0.0.0-20190719004257-d2bd2a29d028 h1:4+4C/Iv2U4fMZBiMCc98MG1In4gJY5YRhtpDNeDeHWs= +golang.org/x/mod v0.7.0 h1:LapD9S96VoQRhi/GrNTqeBJFrUjs5UHCAtTlgwA5oZA= +golang.org/x/oauth2 v0.0.0-20211104180415-d3ed0bb246c8 h1:RerP+noqYHUQ8CMRcPlC2nvTa4dcBIjegkuWdcUDuqg= +golang.org/x/time v0.0.0-20191024005414-555d28b269f0 h1:/5xXl8Y5W96D+TtHSlonuFqGHIWVuyCkGJLwGh9JJFs= +golang.org/x/tools v0.4.0 h1:7mTAgkunk3fr4GAloyyCasadO6h9zSsQZbwvcaIciV4= +golang.org/x/xerrors v0.0.0-20200804184101-5ec99f83aff1 h1:go1bK/D/BFZV2I8cIQd1NKEZ+0owSTG1fDTci4IqFcE= +google.golang.org/api v0.62.0 h1:PhGymJMXfGBzc4lBRmrx9+1w4w2wEzURHNGF/sD/xGc= +google.golang.org/appengine v1.6.7 h1:FZR1q0exgwxzPzp/aF+VccGrSfxfPpkBqjIIEq3ru6c= +google.golang.org/grpc/cmd/protoc-gen-go-grpc v1.1.0 h1:M1YKkFIboKNieVO5DLUEVzQfGwJD30Nv2jfUgzb5UcE= +gopkg.in/alecthomas/kingpin.v2 v2.2.6 h1:jMFz6MfLP0/4fUyZle81rXUoxOBFi19VUFKVDOQfozc= +gopkg.in/errgo.v2 v2.1.0 h1:0vLT13EuvQ0hNvakwLuFZ/jYrLp5F3kcWHXdRggjCE8= +gopkg.in/ini.v1 v1.66.2 h1:XfR1dOYubytKy4Shzc2LHrrGhU0lDCfDGG1yLPmpgsI= +honnef.co/go/tools v0.0.1-2020.1.4 h1:UoveltGrhghAA7ePc+e+QYDHXrBps2PqFZiHkGR/xK8= +rsc.io/binaryregexp v0.2.0 h1:HfqmD5MEmC0zvwBuF187nq9mdnXjXsSivRiXN7SmRkE= +rsc.io/quote/v3 v3.1.0 h1:9JKUTTIUgS6kzR9mK1YuGKv6Nl+DijDNIc0ghT58FaY= +rsc.io/sampler v1.3.0 h1:7uVkIFmeBqHfdjD+gZwtXXI+RODJ2Wc4O7MPEh/QiW4= diff --git a/turborepo-tests/integration/tests/dry_json/monorepo.t b/turborepo-tests/integration/tests/dry_json/monorepo.t index 1761381ba7214..221cec4dd1326 100644 --- a/turborepo-tests/integration/tests/dry_json/monorepo.t +++ b/turborepo-tests/integration/tests/dry_json/monorepo.t @@ -15,7 +15,7 @@ Setup "files": { "foo.txt": "eebae5f3ca7b5831e429e947b7d61edd0de69236" }, - "hashOfExternalDependencies": "ccab0b28617f1f56", + "hashOfExternalDependencies": "459c029558afe716", "globalDotEnv": null, "environmentVariables": { "specified": { @@ -51,12 +51,12 @@ Setup "taskId": "my-app#build", "task": "build", "package": "my-app", - "hash": "0d1e6ee2c143211c", + "hash": "0cd306aa8e337d8a", "inputs": { ".env.local": "e69de29bb2d1d6434b8b29ae775ad8c2e48c5391", "package.json": "6bcf57fd6ff30d1a6f40ad8d8d08e8b940fc7e3b" }, - "hashOfExternalDependencies": "ccab0b28617f1f56", + "hashOfExternalDependencies": "459c029558afe716", "cache": { "local": false, "remote": false, @@ -113,11 +113,11 @@ Setup "taskId": "util#build", "task": "build", "package": "util", - "hash": "76ab904c7ecb2d51", + "hash": "12af4a2f5c5af4e1", "inputs": { "package.json": "4d57bb28c9967640d812981198a743b3188f713e" }, - "hashOfExternalDependencies": "ccab0b28617f1f56", + "hashOfExternalDependencies": "459c029558afe716", "cache": { "local": false, "remote": false, @@ -180,6 +180,5 @@ Run again with NODE_ENV set and see the value in the summary. --filter=util work Tasks that don't exist throw an error $ ${TURBO} run doesnotexist --dry=json - ERROR run failed: error preparing engine: Could not find the following tasks in project: doesnotexist - Turbo error: error preparing engine: Could not find the following tasks in project: doesnotexist + Error: Could not find the following tasks in project: doesnotexist [1] diff --git a/turborepo-tests/integration/tests/dry_json/single_package.t b/turborepo-tests/integration/tests/dry_json/single_package.t index b864e135f8767..dd38ce2724541 100644 --- a/turborepo-tests/integration/tests/dry_json/single_package.t +++ b/turborepo-tests/integration/tests/dry_json/single_package.t @@ -33,7 +33,7 @@ Setup { "taskId": "build", "task": "build", - "hash": "d2295def33764d46", + "hash": "f9360c1870434eb2", "inputs": { ".gitignore": "6f23ff6842b5526da43ab38f4a5bf3b0158eeb42", "package-lock.json": "1c117cce37347befafe3a9cba1b8a609b3600021", diff --git a/turborepo-tests/integration/tests/dry_json/single_package_no_config.t b/turborepo-tests/integration/tests/dry_json/single_package_no_config.t index 785cca23ecd0a..5cf7bbdfc9c3f 100644 --- a/turborepo-tests/integration/tests/dry_json/single_package_no_config.t +++ b/turborepo-tests/integration/tests/dry_json/single_package_no_config.t @@ -34,7 +34,7 @@ Setup { "taskId": "build", "task": "build", - "hash": "a6461c1683e4f102", + "hash": "3f02bc73f1ab0cce", "inputs": { ".gitignore": "6f23ff6842b5526da43ab38f4a5bf3b0158eeb42", "package-lock.json": "1c117cce37347befafe3a9cba1b8a609b3600021", diff --git a/turborepo-tests/integration/tests/dry_json/single_package_with_deps.t b/turborepo-tests/integration/tests/dry_json/single_package_with_deps.t index 62c8a5126f843..b394eccb44d99 100644 --- a/turborepo-tests/integration/tests/dry_json/single_package_with_deps.t +++ b/turborepo-tests/integration/tests/dry_json/single_package_with_deps.t @@ -32,7 +32,7 @@ Setup { "taskId": "build", "task": "build", - "hash": "d6b8b065382193a4", + "hash": "cd720138f792fbca", "inputs": { ".gitignore": "6f23ff6842b5526da43ab38f4a5bf3b0158eeb42", "package-lock.json": "1c117cce37347befafe3a9cba1b8a609b3600021", @@ -87,7 +87,7 @@ Setup { "taskId": "test", "task": "test", - "hash": "1dca8c4431a90e36", + "hash": "118e4fe7f2e841be", "inputs": { ".gitignore": "6f23ff6842b5526da43ab38f4a5bf3b0158eeb42", "package-lock.json": "1c117cce37347befafe3a9cba1b8a609b3600021", diff --git a/turborepo-tests/integration/tests/dry_run.t b/turborepo-tests/integration/tests/dry_run.t index 4a79df4c36145..8138888be6e98 100644 --- a/turborepo-tests/integration/tests/dry_run.t +++ b/turborepo-tests/integration/tests/dry_run.t @@ -18,7 +18,7 @@ Setup $ cat tmp-2.txt Global Hash Inputs Global Files = 1 - External Dependencies Hash = ccab0b28617f1f56 + External Dependencies Hash = 459c029558afe716 Global Cache Key = You don't understand! I coulda had class. I coulda been a contender. I could've been somebody, instead of a bum, which is what I am. Global .env Files Considered = 0 Global Env Vars = SOME_ENV_VAR @@ -32,7 +32,7 @@ Setup my-app#build Task = build Package = my-app - Hash = 0d1e6ee2c143211c + Hash = 0cd306aa8e337d8a Cached (Local) = false Cached (Remote) = false Directory = apps/my-app @@ -53,7 +53,7 @@ Setup util#build Task = build Package = util - Hash = 76ab904c7ecb2d51 + Hash = 12af4a2f5c5af4e1 Cached (Local) = false Cached (Remote) = false Directory = packages/util diff --git a/turborepo-tests/integration/tests/edit_turbo_json/task.t b/turborepo-tests/integration/tests/edit_turbo_json/task.t index 78d4c6a6b8f60..87b7440406def 100644 --- a/turborepo-tests/integration/tests/edit_turbo_json/task.t +++ b/turborepo-tests/integration/tests/edit_turbo_json/task.t @@ -7,15 +7,15 @@ Baseline task hashes $ ${TURBO} build --dry=json | jq -r '.tasks | sort_by(.taskId)[] | {taskId, hash}' { "taskId": "another#build", - "hash": "930c372b34f6fc8c" + "hash": "9b840a9eeed635db" } { "taskId": "my-app#build", - "hash": "1ec581da8a4765ab" + "hash": "4ffefafd578043d5" } { "taskId": "util#build", - "hash": "76ab904c7ecb2d51" + "hash": "12af4a2f5c5af4e1" } Change only my-app#build @@ -23,15 +23,15 @@ Change only my-app#build $ ${TURBO} build --dry=json | jq -r '.tasks | sort_by(.taskId)[] | {taskId, hash}' { "taskId": "another#build", - "hash": "930c372b34f6fc8c" + "hash": "9b840a9eeed635db" } { "taskId": "my-app#build", - "hash": "7beb921347d78bfa" + "hash": "b412269dc6ab1fb0" } { "taskId": "util#build", - "hash": "76ab904c7ecb2d51" + "hash": "12af4a2f5c5af4e1" } Change my-app#build dependsOn @@ -39,15 +39,15 @@ Change my-app#build dependsOn $ ${TURBO} build --dry=json | jq -r '.tasks | sort_by(.taskId)[] | {taskId, hash}' { "taskId": "another#build", - "hash": "930c372b34f6fc8c" + "hash": "9b840a9eeed635db" } { "taskId": "my-app#build", - "hash": "685b9438e3900bed" + "hash": "523d9c8f471c12dd" } { "taskId": "util#build", - "hash": "76ab904c7ecb2d51" + "hash": "12af4a2f5c5af4e1" } Non-materially modifying the dep graph does nothing. @@ -55,15 +55,15 @@ Non-materially modifying the dep graph does nothing. $ ${TURBO} build --dry=json | jq -r '.tasks | sort_by(.taskId)[] | {taskId, hash}' { "taskId": "another#build", - "hash": "930c372b34f6fc8c" + "hash": "9b840a9eeed635db" } { "taskId": "my-app#build", - "hash": "685b9438e3900bed" + "hash": "523d9c8f471c12dd" } { "taskId": "util#build", - "hash": "76ab904c7ecb2d51" + "hash": "12af4a2f5c5af4e1" } @@ -72,13 +72,13 @@ Change util#build impacts itself and my-app $ ${TURBO} build --dry=json | jq -r '.tasks | sort_by(.taskId)[] | {taskId, hash}' { "taskId": "another#build", - "hash": "930c372b34f6fc8c" + "hash": "9b840a9eeed635db" } { "taskId": "my-app#build", - "hash": "bd4e46c0e2fdd071" + "hash": "d053492baf0266c1" } { "taskId": "util#build", - "hash": "f6cfba79415007a3" + "hash": "1e36d9d1795aa2fd" } diff --git a/turborepo-tests/integration/tests/global_env.t b/turborepo-tests/integration/tests/global_env.t index b049da0916c02..94b579fea6aa7 100644 --- a/turborepo-tests/integration/tests/global_env.t +++ b/turborepo-tests/integration/tests/global_env.t @@ -9,7 +9,7 @@ Setup \xe2\x80\xa2 Packages in scope: util (esc) \xe2\x80\xa2 Running build in 1 packages (esc) \xe2\x80\xa2 Remote caching disabled (esc) - util:build: cache miss, executing 76ab904c7ecb2d51 + util:build: cache miss, executing 12af4a2f5c5af4e1 Tasks: 1 successful, 1 total Cached: 0 cached, 1 total @@ -20,7 +20,7 @@ Setup \xe2\x80\xa2 Packages in scope: util (esc) \xe2\x80\xa2 Running build in 1 packages (esc) \xe2\x80\xa2 Remote caching disabled (esc) - util:build: cache hit, suppressing logs 76ab904c7ecb2d51 + util:build: cache hit, suppressing logs 12af4a2f5c5af4e1 Tasks: 1 successful, 1 total Cached: 1 cached, 1 total @@ -31,7 +31,7 @@ Setup \xe2\x80\xa2 Packages in scope: util (esc) \xe2\x80\xa2 Running build in 1 packages (esc) \xe2\x80\xa2 Remote caching disabled (esc) - util:build: cache miss, executing 113a16522caeab3d + util:build: cache miss, executing 88a994f496fbd799 Tasks: 1 successful, 1 total Cached: 0 cached, 1 total @@ -42,7 +42,7 @@ Setup \xe2\x80\xa2 Packages in scope: util (esc) \xe2\x80\xa2 Running build in 1 packages (esc) \xe2\x80\xa2 Remote caching disabled (esc) - util:build: cache hit, suppressing logs 76ab904c7ecb2d51 + util:build: cache hit, suppressing logs 12af4a2f5c5af4e1 Tasks: 1 successful, 1 total Cached: 1 cached, 1 total @@ -53,7 +53,7 @@ Setup \xe2\x80\xa2 Packages in scope: util (esc) \xe2\x80\xa2 Running build in 1 packages (esc) \xe2\x80\xa2 Remote caching disabled (esc) - util:build: cache miss, executing effc9042679b97c6 + util:build: cache miss, executing a3f5173f89d3014c Tasks: 1 successful, 1 total Cached: 0 cached, 1 total diff --git a/turborepo-tests/integration/tests/inference/has_workspaces.t b/turborepo-tests/integration/tests/inference/has_workspaces.t index 81c9622f3f3bf..d4b19af8d9c82 100644 --- a/turborepo-tests/integration/tests/inference/has_workspaces.t +++ b/turborepo-tests/integration/tests/inference/has_workspaces.t @@ -9,8 +9,11 @@ Setup [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::shim: No local turbo binary found at: .* (re) [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::shim: Running command as global turbo (re) [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::cli: pkg_inference_root set to "" (re) + [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::run::global_hash: global hash env vars \[] (re) + [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::run::global_hash: external deps hash: 459c029558afe716 (re) + [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::run::scope::filter: Using as a basis for selecting packages (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: Found go binary at "[\-\w\/]+" (re) - [-0-9:.TWZ+]+ \[DEBUG] turbo: build tag: (go|rust) (re) + [-0-9:.TWZ+]+ \[DEBUG] turbo: build tag: rust (re) [-0-9:.TWZ+]+ \[INFO] turbo: skipping turbod since we appear to be in a non-interactive context (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: filter patterns: patterns=\["nothing"] (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: Parsed selector: selector="&{includeDependencies:false matchDependencies:false includeDependents:false exclude:false excludeSelf:false followProdDepsOnly:false parentDir: namePattern:nothing fromRef: toRefOverride: raw:nothing}" (re) @@ -20,11 +23,13 @@ Setup [-0-9:.TWZ+]+ \[DEBUG] turbo: Filtered packages: cherryPickedPackages=map\[] walkedDependencies=map\[] walkedDependents=map\[] walkedDependentsDependencies=map\[] (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: filtered packages: packages=map\[] (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: global hash env vars: vars=\[] (re) - [-0-9:.TWZ+]+ \[DEBUG] turbo: global hash: value=623b793001bf2614 (re) + [-0-9:.TWZ+]+ \[DEBUG] turbo: global hash: value=3334211b4e6cde03 (re) + [-0-9:.TWZ+]+ \[DEBUG] turbo: global hash matches between Rust and Go (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: local cache folder: path="" (re) \xe2\x80\xa2 Packages in scope: (esc) \xe2\x80\xa2 Running build in 0 packages (esc) \xe2\x80\xa2 Remote caching disabled (esc) + [-0-9:.TWZ+]+ \[DEBUG] turbo: task hashes match (re) No tasks were executed as part of this run. @@ -32,6 +37,7 @@ Setup Cached: 0 cached, 0 total Time:\s*[\.0-9]+m?s (re) + $ cd $TARGET_DIR/apps/web && ${TURBO} run build --filter=nothing -vv [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::shim: Global turbo version: .* (re) [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::shim: Repository Root: .*/has_workspaces\.t (re) @@ -39,8 +45,11 @@ Setup [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::shim: No local turbo binary found at: .* (re) [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::shim: Running command as global turbo (re) [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::cli: pkg_inference_root set to "apps/web" (re) + [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::run::global_hash: global hash env vars \[] (re) + [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::run::global_hash: external deps hash: 459c029558afe716 (re) + [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::run::scope::filter: Using apps/web as a basis for selecting packages (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: Found go binary at "[\-\w\/]+" (re) - [-0-9:.TWZ+]+ \[DEBUG] turbo: build tag: (go|rust) (re) + [-0-9:.TWZ+]+ \[DEBUG] turbo: build tag: rust (re) [-0-9:.TWZ+]+ \[INFO] turbo: skipping turbod since we appear to be in a non-interactive context (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: Using apps/web as a basis for selecting packages (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: filter patterns: patterns=\["nothing"] (re) @@ -51,11 +60,13 @@ Setup [-0-9:.TWZ+]+ \[DEBUG] turbo: Filtered packages: cherryPickedPackages=map\[] walkedDependencies=map\[] walkedDependents=map\[] walkedDependentsDependencies=map\[] (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: filtered packages: packages=map\[] (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: global hash env vars: vars=\[] (re) - [-0-9:.TWZ+]+ \[DEBUG] turbo: global hash: value=623b793001bf2614 (re) + [-0-9:.TWZ+]+ \[DEBUG] turbo: global hash: value=3334211b4e6cde03 (re) + [-0-9:.TWZ+]+ \[DEBUG] turbo: global hash matches between Rust and Go (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: local cache folder: path="" (re) \xe2\x80\xa2 Packages in scope: (esc) \xe2\x80\xa2 Running build in 0 packages (esc) \xe2\x80\xa2 Remote caching disabled (esc) + [-0-9:.TWZ+]+ \[DEBUG] turbo: task hashes match (re) No tasks were executed as part of this run. @@ -70,8 +81,11 @@ Setup [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::shim: No local turbo binary found at: .* (re) [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::shim: Running command as global turbo (re) [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::cli: pkg_inference_root set to "crates" (re) + [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::run::global_hash: global hash env vars \[] (re) + [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::run::global_hash: external deps hash: 459c029558afe716 (re) + [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::run::scope::filter: Using crates as a basis for selecting packages (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: Found go binary at "[\-\w\/]+" (re) - [-0-9:.TWZ+]+ \[DEBUG] turbo: build tag: (go|rust) (re) + [-0-9:.TWZ+]+ \[DEBUG] turbo: build tag: rust (re) [-0-9:.TWZ+]+ \[INFO] turbo: skipping turbod since we appear to be in a non-interactive context (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: Using crates as a basis for selecting packages (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: filter patterns: patterns=\["nothing"] (re) @@ -82,11 +96,13 @@ Setup [-0-9:.TWZ+]+ \[DEBUG] turbo: Filtered packages: cherryPickedPackages=map\[] walkedDependencies=map\[] walkedDependents=map\[] walkedDependentsDependencies=map\[] (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: filtered packages: packages=map\[] (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: global hash env vars: vars=\[] (re) - [-0-9:.TWZ+]+ \[DEBUG] turbo: global hash: value=623b793001bf2614 (re) + [-0-9:.TWZ+]+ \[DEBUG] turbo: global hash: value=3334211b4e6cde03 (re) + [-0-9:.TWZ+]+ \[DEBUG] turbo: global hash matches between Rust and Go (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: local cache folder: path="" (re) \xe2\x80\xa2 Packages in scope: (esc) \xe2\x80\xa2 Running build in 0 packages (esc) \xe2\x80\xa2 Remote caching disabled (esc) + [-0-9:.TWZ+]+ \[DEBUG] turbo: task hashes match (re) No tasks were executed as part of this run. @@ -101,8 +117,11 @@ Setup [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::shim: No local turbo binary found at: .* (re) [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::shim: Running command as global turbo (re) [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::cli: pkg_inference_root set to "crates/super-crate/tests/test-package" (re) + [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::run::global_hash: global hash env vars \[] (re) + [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::run::global_hash: external deps hash: 459c029558afe716 (re) + [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::run::scope::filter: Using crates/super-crate/tests/test-package as a basis for selecting packages (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: Found go binary at "[\-\w\/]+" (re) - [-0-9:.TWZ+]+ \[DEBUG] turbo: build tag: (go|rust) (re) + [-0-9:.TWZ+]+ \[DEBUG] turbo: build tag: rust (re) [-0-9:.TWZ+]+ \[INFO] turbo: skipping turbod since we appear to be in a non-interactive context (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: Using crates/super-crate/tests/test-package as a basis for selecting packages (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: filter patterns: patterns=\["nothing"] (re) @@ -113,11 +132,13 @@ Setup [-0-9:.TWZ+]+ \[DEBUG] turbo: Filtered packages: cherryPickedPackages=map\[] walkedDependencies=map\[] walkedDependents=map\[] walkedDependentsDependencies=map\[] (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: filtered packages: packages=map\[] (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: global hash env vars: vars=\[] (re) - [-0-9:.TWZ+]+ \[DEBUG] turbo: global hash: value=623b793001bf2614 (re) + [-0-9:.TWZ+]+ \[DEBUG] turbo: global hash: value=3334211b4e6cde03 (re) + [-0-9:.TWZ+]+ \[DEBUG] turbo: global hash matches between Rust and Go (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: local cache folder: path="" (re) \xe2\x80\xa2 Packages in scope: (esc) \xe2\x80\xa2 Running build in 0 packages (esc) \xe2\x80\xa2 Remote caching disabled (esc) + [-0-9:.TWZ+]+ \[DEBUG] turbo: task hashes match (re) No tasks were executed as part of this run. @@ -132,8 +153,11 @@ Setup [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::shim: No local turbo binary found at: .* (re) [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::shim: Running command as global turbo (re) [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::cli: pkg_inference_root set to "packages/ui-library/src" (re) + [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::run::global_hash: global hash env vars \[] (re) + [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::run::global_hash: external deps hash: 459c029558afe716 (re) + [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::run::scope::filter: Using packages/ui-library/src as a basis for selecting packages (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: Found go binary at "[\-\w\/]+" (re) - [-0-9:.TWZ+]+ \[DEBUG] turbo: build tag: (go|rust) (re) + [-0-9:.TWZ+]+ \[DEBUG] turbo: build tag: rust (re) [-0-9:.TWZ+]+ \[INFO] turbo: skipping turbod since we appear to be in a non-interactive context (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: Using packages/ui-library/src as a basis for selecting packages (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: filter patterns: patterns=\["nothing"] (re) @@ -144,11 +168,13 @@ Setup [-0-9:.TWZ+]+ \[DEBUG] turbo: Filtered packages: cherryPickedPackages=map\[] walkedDependencies=map\[] walkedDependents=map\[] walkedDependentsDependencies=map\[] (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: filtered packages: packages=map\[] (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: global hash env vars: vars=\[] (re) - [-0-9:.TWZ+]+ \[DEBUG] turbo: global hash: value=623b793001bf2614 (re) + [-0-9:.TWZ+]+ \[DEBUG] turbo: global hash: value=3334211b4e6cde03 (re) + [-0-9:.TWZ+]+ \[DEBUG] turbo: global hash matches between Rust and Go (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: local cache folder: path="" (re) \xe2\x80\xa2 Packages in scope: (esc) \xe2\x80\xa2 Running build in 0 packages (esc) \xe2\x80\xa2 Remote caching disabled (esc) + [-0-9:.TWZ+]+ \[DEBUG] turbo: task hashes match (re) No tasks were executed as part of this run. diff --git a/turborepo-tests/integration/tests/inference/nested_workspaces.t b/turborepo-tests/integration/tests/inference/nested_workspaces.t index 6de117fc18329..40b4a41e040ef 100644 --- a/turborepo-tests/integration/tests/inference/nested_workspaces.t +++ b/turborepo-tests/integration/tests/inference/nested_workspaces.t @@ -9,8 +9,11 @@ Setup [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::shim: No local turbo binary found at: .* (re) [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::shim: Running command as global turbo (re) [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::cli: pkg_inference_root set to "" (re) - [-0-9:.TWZ+]+ \[DEBUG] turbo: Found go binary at "[\-\w\/]+" (re) - [-0-9:.TWZ+]+ \[DEBUG] turbo: build tag: (go|rust) (re) + [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::run::global_hash: global hash env vars \[] (re) + [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::run::global_hash: external deps hash: 459c029558afe716 (re) + [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::run::scope::filter: Using as a basis for selecting packages (re) + [-0-9:.TWZ+]+ \[DEBUG] turbo: Found go binary at "[\-\w\/\.]+" (re) + [-0-9:.TWZ+]+ \[DEBUG] turbo: build tag: rust (re) [-0-9:.TWZ+]+ \[INFO] turbo: skipping turbod since we appear to be in a non-interactive context (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: filter patterns: patterns=\["nothing"] (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: Parsed selector: selector="&{includeDependencies:false matchDependencies:false includeDependents:false exclude:false excludeSelf:false followProdDepsOnly:false parentDir: namePattern:nothing fromRef: toRefOverride: raw:nothing}" (re) @@ -20,11 +23,13 @@ Setup [-0-9:.TWZ+]+ \[DEBUG] turbo: Filtered packages: cherryPickedPackages=map\[] walkedDependencies=map\[] walkedDependents=map\[] walkedDependentsDependencies=map\[] (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: filtered packages: packages=map\[] (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: global hash env vars: vars=\[] (re) - [-0-9:.TWZ+]+ \[DEBUG] turbo: global hash: value=623b793001bf2614 (re) + [-0-9:.TWZ+]+ \[DEBUG] turbo: global hash: value=3334211b4e6cde03 (re) + [-0-9:.TWZ+]+ \[DEBUG] turbo: global hash matches between Rust and Go (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: local cache folder: path="" (re) \xe2\x80\xa2 Packages in scope: (esc) \xe2\x80\xa2 Running build in 0 packages (esc) \xe2\x80\xa2 Remote caching disabled (esc) + [-0-9:.TWZ+]+ \[DEBUG] turbo: task hashes match (re) No tasks were executed as part of this run. @@ -39,8 +44,11 @@ Setup [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::shim: No local turbo binary found at: .* (re) [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::shim: Running command as global turbo (re) [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::cli: pkg_inference_root set to "apps" (re) - [-0-9:.TWZ+]+ \[DEBUG] turbo: Found go binary at "[\-\w\/]+" (re) - [-0-9:.TWZ+]+ \[DEBUG] turbo: build tag: (go|rust) (re) + [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::run::global_hash: global hash env vars \[] (re) + [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::run::global_hash: external deps hash: 459c029558afe716 (re) + [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::run::scope::filter: Using apps as a basis for selecting packages (re) + [-0-9:.TWZ+]+ \[DEBUG] turbo: Found go binary at "[\-\w\/\.]+" (re) + [-0-9:.TWZ+]+ \[DEBUG] turbo: build tag: rust (re) [-0-9:.TWZ+]+ \[INFO] turbo: skipping turbod since we appear to be in a non-interactive context (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: Using apps as a basis for selecting packages (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: filter patterns: patterns=\["nothing"] (re) @@ -51,11 +59,13 @@ Setup [-0-9:.TWZ+]+ \[DEBUG] turbo: Filtered packages: cherryPickedPackages=map\[] walkedDependencies=map\[] walkedDependents=map\[] walkedDependentsDependencies=map\[] (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: filtered packages: packages=map\[] (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: global hash env vars: vars=\[] (re) - [-0-9:.TWZ+]+ \[DEBUG] turbo: global hash: value=623b793001bf2614 (re) + [-0-9:.TWZ+]+ \[DEBUG] turbo: global hash: value=3334211b4e6cde03 (re) + [-0-9:.TWZ+]+ \[DEBUG] turbo: global hash matches between Rust and Go (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: local cache folder: path="" (re) \xe2\x80\xa2 Packages in scope: (esc) \xe2\x80\xa2 Running build in 0 packages (esc) \xe2\x80\xa2 Remote caching disabled (esc) + [-0-9:.TWZ+]+ \[DEBUG] turbo: task hashes match (re) No tasks were executed as part of this run. @@ -70,8 +80,11 @@ Setup [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::shim: No local turbo binary found at: .* (re) [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::shim: Running command as global turbo (re) [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::cli: pkg_inference_root set to "" (re) - [-0-9:.TWZ+]+ \[DEBUG] turbo: Found go binary at "[\-\w\/]+" (re) - [-0-9:.TWZ+]+ \[DEBUG] turbo: build tag: (go|rust) (re) + [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::run::global_hash: global hash env vars \[] (re) + [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::run::global_hash: external deps hash: 459c029558afe716 (re) + [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::run::scope::filter: Using as a basis for selecting packages (re) + [-0-9:.TWZ+]+ \[DEBUG] turbo: Found go binary at "[\-\w\/\.]+" (re) + [-0-9:.TWZ+]+ \[DEBUG] turbo: build tag: rust (re) [-0-9:.TWZ+]+ \[INFO] turbo: skipping turbod since we appear to be in a non-interactive context (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: filter patterns: patterns=\["nothing"] (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: Parsed selector: selector="&{includeDependencies:false matchDependencies:false includeDependents:false exclude:false excludeSelf:false followProdDepsOnly:false parentDir: namePattern:nothing fromRef: toRefOverride: raw:nothing}" (re) @@ -81,11 +94,13 @@ Setup [-0-9:.TWZ+]+ \[DEBUG] turbo: Filtered packages: cherryPickedPackages=map\[] walkedDependencies=map\[] walkedDependents=map\[] walkedDependentsDependencies=map\[] (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: filtered packages: packages=map\[] (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: global hash env vars: vars=\[] (re) - [-0-9:.TWZ+]+ \[DEBUG] turbo: global hash: value=623b793001bf2614 (re) + [-0-9:.TWZ+]+ \[DEBUG] turbo: global hash: value=3334211b4e6cde03 (re) + [-0-9:.TWZ+]+ \[DEBUG] turbo: global hash matches between Rust and Go (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: local cache folder: path="" (re) \xe2\x80\xa2 Packages in scope: (esc) \xe2\x80\xa2 Running build in 0 packages (esc) \xe2\x80\xa2 Remote caching disabled (esc) + [-0-9:.TWZ+]+ \[DEBUG] turbo: task hashes match (re) No tasks were executed as part of this run. @@ -100,8 +115,11 @@ Setup [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::shim: No local turbo binary found at: .* (re) [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::shim: Running command as global turbo (re) [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::cli: pkg_inference_root set to "apps" (re) - [-0-9:.TWZ+]+ \[DEBUG] turbo: Found go binary at "[\-\w\/]+" (re) - [-0-9:.TWZ+]+ \[DEBUG] turbo: build tag: (go|rust) (re) + [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::run::global_hash: global hash env vars \[] (re) + [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::run::global_hash: external deps hash: 459c029558afe716 (re) + [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::run::scope::filter: Using apps as a basis for selecting packages (re) + [-0-9:.TWZ+]+ \[DEBUG] turbo: Found go binary at "[\-\w\/\.]+" (re) + [-0-9:.TWZ+]+ \[DEBUG] turbo: build tag: rust (re) [-0-9:.TWZ+]+ \[INFO] turbo: skipping turbod since we appear to be in a non-interactive context (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: Using apps as a basis for selecting packages (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: filter patterns: patterns=\["nothing"] (re) @@ -112,11 +130,13 @@ Setup [-0-9:.TWZ+]+ \[DEBUG] turbo: Filtered packages: cherryPickedPackages=map\[] walkedDependencies=map\[] walkedDependents=map\[] walkedDependentsDependencies=map\[] (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: filtered packages: packages=map\[] (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: global hash env vars: vars=\[] (re) - [-0-9:.TWZ+]+ \[DEBUG] turbo: global hash: value=623b793001bf2614 (re) + [-0-9:.TWZ+]+ \[DEBUG] turbo: global hash: value=3334211b4e6cde03 (re) + [-0-9:.TWZ+]+ \[DEBUG] turbo: global hash matches between Rust and Go (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: local cache folder: path="" (re) \xe2\x80\xa2 Packages in scope: (esc) \xe2\x80\xa2 Running build in 0 packages (esc) \xe2\x80\xa2 Remote caching disabled (esc) + [-0-9:.TWZ+]+ \[DEBUG] turbo: task hashes match (re) No tasks were executed as part of this run. @@ -131,8 +151,11 @@ Setup [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::shim: No local turbo binary found at: .* (re) [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::shim: Running command as global turbo (re) [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::cli: pkg_inference_root set to "inner-no-turbo" (re) - [-0-9:.TWZ+]+ \[DEBUG] turbo: Found go binary at "[\-\w\/]+" (re) - [-0-9:.TWZ+]+ \[DEBUG] turbo: build tag: (go|rust) (re) + [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::run::global_hash: global hash env vars \[] (re) + [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::run::global_hash: external deps hash: 459c029558afe716 (re) + [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::run::scope::filter: Using inner-no-turbo as a basis for selecting packages (re) + [-0-9:.TWZ+]+ \[DEBUG] turbo: Found go binary at "[\-\w\/\.]+" (re) + [-0-9:.TWZ+]+ \[DEBUG] turbo: build tag: rust (re) [-0-9:.TWZ+]+ \[INFO] turbo: skipping turbod since we appear to be in a non-interactive context (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: Using inner-no-turbo as a basis for selecting packages (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: filter patterns: patterns=\["nothing"] (re) @@ -143,11 +166,13 @@ Setup [-0-9:.TWZ+]+ \[DEBUG] turbo: Filtered packages: cherryPickedPackages=map\[] walkedDependencies=map\[] walkedDependents=map\[] walkedDependentsDependencies=map\[] (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: filtered packages: packages=map\[] (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: global hash env vars: vars=\[] (re) - [-0-9:.TWZ+]+ \[DEBUG] turbo: global hash: value=623b793001bf2614 (re) + [-0-9:.TWZ+]+ \[DEBUG] turbo: global hash: value=3334211b4e6cde03 (re) + [-0-9:.TWZ+]+ \[DEBUG] turbo: global hash matches between Rust and Go (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: local cache folder: path="" (re) \xe2\x80\xa2 Packages in scope: (esc) \xe2\x80\xa2 Running build in 0 packages (esc) \xe2\x80\xa2 Remote caching disabled (esc) + [-0-9:.TWZ+]+ \[DEBUG] turbo: task hashes match (re) No tasks were executed as part of this run. @@ -162,8 +187,11 @@ Setup [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::shim: No local turbo binary found at: .* (re) [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::shim: Running command as global turbo (re) [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::cli: pkg_inference_root set to "inner-no-turbo/apps" (re) - [-0-9:.TWZ+]+ \[DEBUG] turbo: Found go binary at "[\-\w\/]+" (re) - [-0-9:.TWZ+]+ \[DEBUG] turbo: build tag: (go|rust) (re) + [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::run::global_hash: global hash env vars \[] (re) + [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::run::global_hash: external deps hash: 459c029558afe716 (re) + [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::run::scope::filter: Using inner-no-turbo/apps as a basis for selecting packages (re) + [-0-9:.TWZ+]+ \[DEBUG] turbo: Found go binary at "[\-\w\/\.]+" (re) + [-0-9:.TWZ+]+ \[DEBUG] turbo: build tag: rust (re) [-0-9:.TWZ+]+ \[INFO] turbo: skipping turbod since we appear to be in a non-interactive context (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: Using inner-no-turbo/apps as a basis for selecting packages (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: filter patterns: patterns=\["nothing"] (re) @@ -174,11 +202,13 @@ Setup [-0-9:.TWZ+]+ \[DEBUG] turbo: Filtered packages: cherryPickedPackages=map\[] walkedDependencies=map\[] walkedDependents=map\[] walkedDependentsDependencies=map\[] (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: filtered packages: packages=map\[] (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: global hash env vars: vars=\[] (re) - [-0-9:.TWZ+]+ \[DEBUG] turbo: global hash: value=623b793001bf2614 (re) + [-0-9:.TWZ+]+ \[DEBUG] turbo: global hash: value=3334211b4e6cde03 (re) + [-0-9:.TWZ+]+ \[DEBUG] turbo: global hash matches between Rust and Go (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: local cache folder: path="" (re) \xe2\x80\xa2 Packages in scope: (esc) \xe2\x80\xa2 Running build in 0 packages (esc) \xe2\x80\xa2 Remote caching disabled (esc) + [-0-9:.TWZ+]+ \[DEBUG] turbo: task hashes match (re) No tasks were executed as part of this run. @@ -193,27 +223,17 @@ Setup [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::shim: No local turbo binary found at: .* (re) [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::shim: Running command as global turbo (re) [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::cli: pkg_inference_root set to "" (re) - [-0-9:.TWZ+]+ \[DEBUG] turbo: Found go binary at "[\-\w\/]+" (re) - [-0-9:.TWZ+]+ \[DEBUG] turbo: build tag: (go|rust) (re) - [-0-9:.TWZ+]+ \[INFO] turbo: skipping turbod since we appear to be in a non-interactive context (re) - [-0-9:.TWZ+]+ \[ERROR] turbo: error: run failed: Could not find turbo\.json\. Follow directions at https://turbo\.build/repo/docs to create one: file does not exist (re) - ERROR run failed: Could not find turbo.json. Follow directions at https://turbo.build/repo/docs to create one: file does not exist - Turbo error: Could not find turbo.json. Follow directions at https://turbo.build/repo/docs to create one: file does not exist + Error: Could not find turbo.json. Follow directions at https://turbo.build/repo/docs to create one [1] $ cd $TARGET_DIR/outer-no-turbo/apps && ${TURBO} run build --filter=nothing -vv [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::shim: Global turbo version: .* (re) - [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::shim: Repository Root: .*/nested_workspaces/outer-no-turbo (re) - [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::shim: No local turbo binary found at: .* (re) - [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::shim: No local turbo binary found at: .* (re) + [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::shim: Repository Root: [\-\w\/\.]+ (re) + [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::shim: No local turbo binary found at: [\-\w\/\.]+ (re) + [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::shim: No local turbo binary found at: [\-\w\/\.]+ (re) [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::shim: Running command as global turbo (re) [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::cli: pkg_inference_root set to "apps" (re) - [-0-9:.TWZ+]+ \[DEBUG] turbo: Found go binary at "[\-\w\/]+" (re) - [-0-9:.TWZ+]+ \[DEBUG] turbo: build tag: (go|rust) (re) - [-0-9:.TWZ+]+ \[INFO] turbo: skipping turbod since we appear to be in a non-interactive context (re) - [-0-9:.TWZ+]+ \[ERROR] turbo: error: run failed: Could not find turbo\.json\. Follow directions at https://turbo\.build/repo/docs to create one: file does not exist (re) - ERROR run failed: Could not find turbo.json. Follow directions at https://turbo.build/repo/docs to create one: file does not exist - Turbo error: Could not find turbo.json. Follow directions at https://turbo.build/repo/docs to create one: file does not exist + Error: Could not find turbo.json. Follow directions at https://turbo.build/repo/docs to create one [1] $ cd $TARGET_DIR/outer-no-turbo/inner && ${TURBO} run build --filter=nothing -vv @@ -223,7 +243,10 @@ Setup [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::shim: No local turbo binary found at: .* (re) [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::shim: Running command as global turbo (re) [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::cli: pkg_inference_root set to "" (re) - [-0-9:.TWZ+]+ \[DEBUG] turbo: Found go binary at "[\-\w\/]+" (re) + [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::run::global_hash: global hash env vars \[] (re) + [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::run::global_hash: external deps hash: 459c029558afe716 (re) + [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::run::scope::filter: Using as a basis for selecting packages (re) + [-0-9:.TWZ+]+ \[DEBUG] turbo: Found go binary at "[\-\w\/\.]+" (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: build tag: (go|rust) (re) [-0-9:.TWZ+]+ \[INFO] turbo: skipping turbod since we appear to be in a non-interactive context (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: filter patterns: patterns=\["nothing"] (re) @@ -234,11 +257,13 @@ Setup [-0-9:.TWZ+]+ \[DEBUG] turbo: Filtered packages: cherryPickedPackages=map\[] walkedDependencies=map\[] walkedDependents=map\[] walkedDependentsDependencies=map\[] (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: filtered packages: packages=map\[] (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: global hash env vars: vars=\[] (re) - [-0-9:.TWZ+]+ \[DEBUG] turbo: global hash: value=623b793001bf2614 (re) + [-0-9:.TWZ+]+ \[DEBUG] turbo: global hash: value=3334211b4e6cde03 (re) + [-0-9:.TWZ+]+ \[DEBUG] turbo: global hash matches between Rust and Go (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: local cache folder: path="" (re) \xe2\x80\xa2 Packages in scope: (esc) \xe2\x80\xa2 Running build in 0 packages (esc) \xe2\x80\xa2 Remote caching disabled (esc) + [-0-9:.TWZ+]+ \[DEBUG] turbo: task hashes match (re) No tasks were executed as part of this run. @@ -253,8 +278,11 @@ Setup [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::shim: No local turbo binary found at: .* (re) [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::shim: Running command as global turbo (re) [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::cli: pkg_inference_root set to "apps" (re) - [-0-9:.TWZ+]+ \[DEBUG] turbo: Found go binary at "[\-\w\/]+" (re) - [-0-9:.TWZ+]+ \[DEBUG] turbo: build tag: (go|rust) (re) + [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::run::global_hash: global hash env vars \[] (re) + [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::run::global_hash: external deps hash: 459c029558afe716 (re) + [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::run::scope::filter: Using apps as a basis for selecting packages (re) + [-0-9:.TWZ+]+ \[DEBUG] turbo: Found go binary at "[\-\w\/\.]+" (re) + [-0-9:.TWZ+]+ \[DEBUG] turbo: build tag: rust (re) [-0-9:.TWZ+]+ \[INFO] turbo: skipping turbod since we appear to be in a non-interactive context (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: Using apps as a basis for selecting packages (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: filter patterns: patterns=\["nothing"] (re) @@ -265,11 +293,13 @@ Setup [-0-9:.TWZ+]+ \[DEBUG] turbo: Filtered packages: cherryPickedPackages=map\[] walkedDependencies=map\[] walkedDependents=map\[] walkedDependentsDependencies=map\[] (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: filtered packages: packages=map\[] (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: global hash env vars: vars=\[] (re) - [-0-9:.TWZ+]+ \[DEBUG] turbo: global hash: value=623b793001bf2614 (re) + [-0-9:.TWZ+]+ \[DEBUG] turbo: global hash: value=3334211b4e6cde03 (re) + [-0-9:.TWZ+]+ \[DEBUG] turbo: global hash matches between Rust and Go (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: local cache folder: path="" (re) \xe2\x80\xa2 Packages in scope: (esc) \xe2\x80\xa2 Running build in 0 packages (esc) \xe2\x80\xa2 Remote caching disabled (esc) + [-0-9:.TWZ+]+ \[DEBUG] turbo: task hashes match (re) No tasks were executed as part of this run. @@ -284,12 +314,7 @@ Setup [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::shim: No local turbo binary found at: .* (re) [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::shim: Running command as global turbo (re) [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::cli: pkg_inference_root set to "" (re) - [-0-9:.TWZ+]+ \[DEBUG] turbo: Found go binary at "[\-\w\/]+" (re) - [-0-9:.TWZ+]+ \[DEBUG] turbo: build tag: (go|rust) (re) - [-0-9:.TWZ+]+ \[INFO] turbo: skipping turbod since we appear to be in a non-interactive context (re) - [-0-9:.TWZ+]+ \[ERROR] turbo: error: run failed: Could not find turbo\.json\. Follow directions at https://turbo\.build/repo/docs to create one: file does not exist (re) - ERROR run failed: Could not find turbo.json. Follow directions at https://turbo.build/repo/docs to create one: file does not exist - Turbo error: Could not find turbo.json. Follow directions at https://turbo.build/repo/docs to create one: file does not exist + Error: Could not find turbo.json. Follow directions at https://turbo.build/repo/docs to create one [1] $ cd $TARGET_DIR/outer-no-turbo/inner-no-turbo/apps && ${TURBO} run build --filter=nothing -vv @@ -299,10 +324,5 @@ Setup [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::shim: No local turbo binary found at: .* (re) [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::shim: Running command as global turbo (re) [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::cli: pkg_inference_root set to "apps" (re) - [-0-9:.TWZ+]+ \[DEBUG] turbo: Found go binary at "[\-\w\/]+" (re) - [-0-9:.TWZ+]+ \[DEBUG] turbo: build tag: (go|rust) (re) - [-0-9:.TWZ+]+ \[INFO] turbo: skipping turbod since we appear to be in a non-interactive context (re) - [-0-9:.TWZ+]+ \[ERROR] turbo: error: run failed: Could not find turbo\.json\. Follow directions at https://turbo\.build/repo/docs to create one: file does not exist (re) - ERROR run failed: Could not find turbo.json. Follow directions at https://turbo.build/repo/docs to create one: file does not exist - Turbo error: Could not find turbo.json. Follow directions at https://turbo.build/repo/docs to create one: file does not exist + Error: Could not find turbo.json. Follow directions at https://turbo.build/repo/docs to create one [1] diff --git a/turborepo-tests/integration/tests/inference/no_workspaces.t b/turborepo-tests/integration/tests/inference/no_workspaces.t index 7b56d44570268..1243babb9fd28 100644 --- a/turborepo-tests/integration/tests/inference/no_workspaces.t +++ b/turborepo-tests/integration/tests/inference/no_workspaces.t @@ -9,8 +9,11 @@ Setup [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::shim: No local turbo binary found at: .* (re) [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::shim: Running command as global turbo (re) [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::cli: pkg_inference_root set to "" (re) + [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::run::global_hash: global hash env vars \[] (re) + [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::run::global_hash: external deps hash: no hash \(single package\) (re) + [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::run::scope::filter: Using as a basis for selecting packages (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: Found go binary at "[\-\w\/]+" (re) - [-0-9:.TWZ+]+ \[DEBUG] turbo: build tag: (go|rust) (re) + [-0-9:.TWZ+]+ \[DEBUG] turbo: build tag: rust (re) [-0-9:.TWZ+]+ \[INFO] turbo: skipping turbod since we appear to be in a non-interactive context (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: filter patterns: patterns=\["nothing"] (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: Parsed selector: selector="&{includeDependencies:false matchDependencies:false includeDependents:false exclude:false excludeSelf:false followProdDepsOnly:false parentDir: namePattern:nothing fromRef: toRefOverride: raw:nothing}" (re) @@ -20,10 +23,12 @@ Setup [-0-9:.TWZ+]+ \[DEBUG] turbo: Filtered packages: cherryPickedPackages=map\[] walkedDependencies=map\[] walkedDependents=map\[] walkedDependentsDependencies=map\[] (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: filtered packages: packages=map\[] (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: global hash env vars: vars=\[] (re) - [-0-9:.TWZ+]+ \[DEBUG] turbo: global hash: value=b3dc914d74316433 (re) + [-0-9:.TWZ+]+ \[DEBUG] turbo: global hash: value=dc8feb7ec0a6cc34 (re) + [-0-9:.TWZ+]+ \[DEBUG] turbo: global hash matches between Rust and Go (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: local cache folder: path="" (re) \xe2\x80\xa2 Running build (esc) \xe2\x80\xa2 Remote caching disabled (esc) + [-0-9:.TWZ+]+ \[DEBUG] turbo: task hashes match (re) No tasks were executed as part of this run. @@ -38,6 +43,9 @@ Setup [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::shim: No local turbo binary found at: .* (re) [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::shim: Running command as global turbo (re) [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::cli: pkg_inference_root set to "" (re) + [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::run::global_hash: global hash env vars \[] (re) + [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::run::global_hash: external deps hash: no hash \(single package\) (re) + [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::run::scope::filter: Using as a basis for selecting packages (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: Found go binary at "[\-\w\/]+" (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: build tag: (go|rust) (re) [-0-9:.TWZ+]+ \[INFO] turbo: skipping turbod since we appear to be in a non-interactive context (re) @@ -49,10 +57,12 @@ Setup [-0-9:.TWZ+]+ \[DEBUG] turbo: Filtered packages: cherryPickedPackages=map\[] walkedDependencies=map\[] walkedDependents=map\[] walkedDependentsDependencies=map\[] (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: filtered packages: packages=map\[] (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: global hash env vars: vars=\[] (re) - [-0-9:.TWZ+]+ \[DEBUG] turbo: global hash: value=b76f12ffa66eaf29 (re) + [-0-9:.TWZ+]+ \[DEBUG] turbo: global hash: value=999206ff8ba1bf87 (re) + [-0-9:.TWZ+]+ \[DEBUG] turbo: global hash matches between Rust and Go (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: local cache folder: path="" (re) \xe2\x80\xa2 Running build (esc) \xe2\x80\xa2 Remote caching disabled (esc) + [-0-9:.TWZ+]+ \[DEBUG] turbo: task hashes match (re) No tasks were executed as part of this run. @@ -67,6 +77,9 @@ Setup [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::shim: No local turbo binary found at: .* (re) [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::shim: Running command as global turbo (re) [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::cli: pkg_inference_root set to "" (re) + [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::run::global_hash: global hash env vars \[] (re) + [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::run::global_hash: external deps hash: no hash \(single package\) (re) + [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::run::scope::filter: Using as a basis for selecting packages (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: Found go binary at "[\-\w\/]+" (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: build tag: (go|rust) (re) [-0-9:.TWZ+]+ \[INFO] turbo: skipping turbod since we appear to be in a non-interactive context (re) @@ -78,10 +91,12 @@ Setup [-0-9:.TWZ+]+ \[DEBUG] turbo: Filtered packages: cherryPickedPackages=map\[] walkedDependencies=map\[] walkedDependents=map\[] walkedDependentsDependencies=map\[] (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: filtered packages: packages=map\[] (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: global hash env vars: vars=\[] (re) - [-0-9:.TWZ+]+ \[DEBUG] turbo: global hash: value=cdaabfe0ec87db4e (re) + [-0-9:.TWZ+]+ \[DEBUG] turbo: global hash: value=ec249bff3bde08fe (re) + [-0-9:.TWZ+]+ \[DEBUG] turbo: global hash matches between Rust and Go (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: local cache folder: path="" (re) \xe2\x80\xa2 Running build (esc) \xe2\x80\xa2 Remote caching disabled (esc) + [-0-9:.TWZ+]+ \[DEBUG] turbo: task hashes match (re) No tasks were executed as part of this run. diff --git a/turborepo-tests/integration/tests/inference/no_workspaces_setup.sh b/turborepo-tests/integration/tests/inference/no_workspaces_setup.sh old mode 100644 new mode 100755 diff --git a/turborepo-tests/integration/tests/inference/package-lock.json b/turborepo-tests/integration/tests/inference/package-lock.json new file mode 100644 index 0000000000000..801445fe8866f --- /dev/null +++ b/turborepo-tests/integration/tests/inference/package-lock.json @@ -0,0 +1,6 @@ +{ + "name": "inference", + "lockfileVersion": 3, + "requires": true, + "packages": {} +} diff --git a/turborepo-tests/integration/tests/ordered/github.t b/turborepo-tests/integration/tests/ordered/github.t index 04f70383e8116..a1435ac5eece9 100644 --- a/turborepo-tests/integration/tests/ordered/github.t +++ b/turborepo-tests/integration/tests/ordered/github.t @@ -10,7 +10,7 @@ because otherwise prysk interprets them as multiline commands \xe2\x80\xa2 Running build in 2 packages (esc) \xe2\x80\xa2 Remote caching disabled (esc) ::group::my-app:build - cache bypass, force executing 4c3a4e8d472d74b2 + cache bypass, force executing 1a6d015eb2c23615 >\sbuild (re) >\secho 'building' && sleep 1 && echo 'done' (re) @@ -19,7 +19,7 @@ because otherwise prysk interprets them as multiline commands done ::endgroup:: ::group::util:build - cache bypass, force executing 90d7154e362e3386 + cache bypass, force executing 329a30aa0bee6760 >\sbuild (re) >\ssleep 0.5 && echo 'building' && sleep 1 && echo 'completed' (re) @@ -38,7 +38,7 @@ because otherwise prysk interprets them as multiline commands \xe2\x80\xa2 Running build in 1 packages (esc) \xe2\x80\xa2 Remote caching disabled (esc) ::group::util:build - util:build: cache bypass, force executing 90d7154e362e3386 + util:build: cache bypass, force executing 329a30aa0bee6760 util:build: util:build: > build util:build: > sleep 0.5 && echo 'building' && sleep 1 && echo 'completed' @@ -58,7 +58,7 @@ Verify that errors are grouped properly \xe2\x80\xa2 Running fail in 2 packages (esc) \xe2\x80\xa2 Remote caching disabled (esc) ::group::util:fail - cache miss, executing 9bf2c727d81cf834 + cache miss, executing 8e52ba9b36ee852c \> fail (re) \> echo 'failing'; exit 1 (re) diff --git a/turborepo-tests/integration/tests/package_manager.t b/turborepo-tests/integration/tests/package_manager.t index aafc9c6055c61..4e8152ce92e7f 100644 --- a/turborepo-tests/integration/tests/package_manager.t +++ b/turborepo-tests/integration/tests/package_manager.t @@ -3,14 +3,14 @@ Setup $ . ${TESTDIR}/_helpers/setup_monorepo.sh $(pwd) basic_monorepo "npm@8.19.4" Run test run - $ ${TURBO} run build --__test-run | jq .package_manager + $ TURBO_LOG_VERBOSITY=off ${TURBO} run build --__test-run | jq .package_manager "npm" Set package manager to yarn in package.json $ jq '.packageManager = "yarn@1.22.7"' package.json > package.json.tmp && mv package.json.tmp package.json Run test run - $ ${TURBO} run build --__test-run | jq .package_manager + $ TURBO_LOG_VERBOSITY=off ${TURBO} run build --__test-run | jq .package_manager "yarn" Set up .yarnrc.yml @@ -20,21 +20,25 @@ Set package manager to berry in package.json $ jq '.packageManager = "yarn@2.0.0"' package.json > package.json.tmp && mv package.json.tmp package.json Run test run - $ ${TURBO} run build --__test-run | jq .package_manager + $ TURBO_LOG_VERBOSITY=off ${TURBO} run build --__test-run | jq .package_manager "berry" Set package manager to pnpm6 in package.json $ jq '.packageManager = "pnpm@6.0.0"' package.json > package.json.tmp && mv package.json.tmp package.json +Set up pnpm-workspace.yaml + $ echo "packages:" >> pnpm-workspace.yaml + $ echo " - apps/*" >> pnpm-workspace.yaml + Run test run - $ ${TURBO} run build --__test-run | jq .package_manager + $ TURBO_LOG_VERBOSITY=off ${TURBO} run build --__test-run | jq .package_manager "pnpm6" Set package manager to pnpm in package.json $ jq '.packageManager = "pnpm@7.0.0"' package.json > package.json.tmp && mv package.json.tmp package.json Run test run - $ ${TURBO} run build --__test-run | jq .package_manager + $ TURBO_LOG_VERBOSITY=off ${TURBO} run build --__test-run | jq .package_manager "pnpm" Clear package manager field in package.json @@ -51,7 +55,7 @@ Create yarn.lock $ touch yarn.lock Run test run - $ ${TURBO} run build --__test-run | jq .package_manager + $ TURBO_LOG_VERBOSITY=off ${TURBO} run build --__test-run | jq .package_manager "yarn" Use yarn 3.5.1 @@ -59,7 +63,7 @@ Use yarn 3.5.1 Preparing yarn@3.5.1 for immediate activation... Run test run - $ ${TURBO} run build --__test-run | jq .package_manager + $ TURBO_LOG_VERBOSITY=off ${TURBO} run build --__test-run | jq .package_manager "berry" Delete yarn.lock @@ -69,7 +73,7 @@ Create pnpm-lock.yaml $ touch pnpm-lock.yaml Run test run - $ ${TURBO} run build --__test-run | jq .package_manager + $ TURBO_LOG_VERBOSITY=off ${TURBO} run build --__test-run | jq .package_manager "pnpm" Delete pnpm-lock.yaml @@ -79,5 +83,5 @@ Create package-lock.json $ touch package-lock.json Run test run - $ ${TURBO} run build --__test-run | jq .package_manager + $ TURBO_LOG_VERBOSITY=off ${TURBO} run build --__test-run | jq .package_manager "npm" \ No newline at end of file diff --git a/turborepo-tests/integration/tests/persistent_dependencies/6-topological-unimplemented.t b/turborepo-tests/integration/tests/persistent_dependencies/6-topological-unimplemented.t index 85961d398e628..8ad8820776bde 100644 --- a/turborepo-tests/integration/tests/persistent_dependencies/6-topological-unimplemented.t +++ b/turborepo-tests/integration/tests/persistent_dependencies/6-topological-unimplemented.t @@ -18,7 +18,7 @@ \xe2\x80\xa2 Packages in scope: app-a, pkg-a (esc) \xe2\x80\xa2 Running dev in 2 packages (esc) \xe2\x80\xa2 Remote caching disabled (esc) - app-a:dev: cache miss, executing 330b88bf8320c036 + app-a:dev: cache miss, executing fd9310330d841536 app-a:dev: app-a:dev: > dev app-a:dev: > echo 'dev app-a' diff --git a/turborepo-tests/integration/tests/pkg-inference.t b/turborepo-tests/integration/tests/pkg-inference.t index 1ae22aba10aff..17c615ddcb1e9 100644 --- a/turborepo-tests/integration/tests/pkg-inference.t +++ b/turborepo-tests/integration/tests/pkg-inference.t @@ -7,7 +7,7 @@ Setup \xe2\x80\xa2 Packages in scope: util (esc) \xe2\x80\xa2 Running build in 1 packages (esc) \xe2\x80\xa2 Remote caching disabled (esc) - util:build: cache miss, executing 76ab904c7ecb2d51 + util:build: cache miss, executing 12af4a2f5c5af4e1 util:build: util:build: > build util:build: > echo 'building' diff --git a/turborepo-tests/integration/tests/prune/composable-config.t b/turborepo-tests/integration/tests/prune/composable-config.t index c3ddc2683c592..63c650f82a1e7 100644 --- a/turborepo-tests/integration/tests/prune/composable-config.t +++ b/turborepo-tests/integration/tests/prune/composable-config.t @@ -12,7 +12,7 @@ Make sure that the internal util package is part of the prune output \xe2\x80\xa2 Packages in scope: docs, shared, util (esc) \xe2\x80\xa2 Running new-task in 3 packages (esc) \xe2\x80\xa2 Remote caching disabled (esc) - docs:new-task: cache miss, executing b11eb1b476230aa4 + docs:new-task: cache miss, executing 946f33a847be44be docs:new-task: docs:new-task: > docs@ new-task .*out/apps/docs (re) docs:new-task: > echo 'running new task' diff --git a/turborepo-tests/integration/tests/run-caching/excluded-inputs.t b/turborepo-tests/integration/tests/run-caching/excluded-inputs.t index 882e9dd8982c8..355653b4a4e8e 100644 --- a/turborepo-tests/integration/tests/run-caching/excluded-inputs.t +++ b/turborepo-tests/integration/tests/run-caching/excluded-inputs.t @@ -7,7 +7,7 @@ Running build for my-app succeeds \xe2\x80\xa2 Packages in scope: my-app (esc) \xe2\x80\xa2 Running build in 1 packages (esc) \xe2\x80\xa2 Remote caching disabled (esc) - my-app:build: cache miss, executing ba39dbae281ef72a + my-app:build: cache miss, executing 48b509716a9c0812 my-app:build: my-app:build: > build my-app:build: > echo 'building' @@ -24,7 +24,7 @@ Update exluded file and try again \xe2\x80\xa2 Packages in scope: my-app (esc) \xe2\x80\xa2 Running build in 1 packages (esc) \xe2\x80\xa2 Remote caching disabled (esc) - my-app:build: cache hit, replaying logs ba39dbae281ef72a + my-app:build: cache hit, replaying logs 48b509716a9c0812 my-app:build: my-app:build: > build my-app:build: > echo 'building' diff --git a/turborepo-tests/integration/tests/run-logging/errors-only.t b/turborepo-tests/integration/tests/run-logging/errors-only.t index b33b93aa4dd2f..3e72cc98faa52 100644 --- a/turborepo-tests/integration/tests/run-logging/errors-only.t +++ b/turborepo-tests/integration/tests/run-logging/errors-only.t @@ -38,7 +38,7 @@ Setup \xe2\x80\xa2 Packages in scope: app-a (esc) \xe2\x80\xa2 Running builderror in 1 packages (esc) \xe2\x80\xa2 Remote caching disabled (esc) - app-a:builderror: cache miss, executing 8dbe2bf2bd05c8d6 + app-a:builderror: cache miss, executing d835aa6c7249b05b app-a:builderror: app-a:builderror: > builderror app-a:builderror: > echo "error builderror app-a!" && exit 1 @@ -68,7 +68,7 @@ Setup \xe2\x80\xa2 Packages in scope: app-a (esc) \xe2\x80\xa2 Running builderror2 in 1 packages (esc) \xe2\x80\xa2 Remote caching disabled (esc) - app-a:builderror2: cache miss, executing c4bbc2a5b473fe4f + app-a:builderror2: cache miss, executing 52d2d4ddf382b5d9 app-a:builderror2: app-a:builderror2: > builderror2 app-a:builderror2: > echo "error builderror2 app-a!" && exit 1 diff --git a/turborepo-tests/integration/tests/run-logging/log_prefix.t b/turborepo-tests/integration/tests/run-logging/log_prefix.t index 553d2ef7d12e2..67f97b90a7e1e 100644 --- a/turborepo-tests/integration/tests/run-logging/log_prefix.t +++ b/turborepo-tests/integration/tests/run-logging/log_prefix.t @@ -7,7 +7,7 @@ Setup \xe2\x80\xa2 Packages in scope: app-a (esc) \xe2\x80\xa2 Running build in 1 packages (esc) \xe2\x80\xa2 Remote caching disabled (esc) - cache miss, executing 906851cd5c1e12d4 + cache miss, executing a1cf9d257ab9b1bf \> build (re) \> echo 'build app-a' (re) @@ -31,7 +31,7 @@ Setup \xe2\x80\xa2 Packages in scope: app-a (esc) \xe2\x80\xa2 Running build in 1 packages (esc) \xe2\x80\xa2 Remote caching disabled (esc) - cache hit, replaying logs 906851cd5c1e12d4 + cache hit, replaying logs a1cf9d257ab9b1bf \> build (re) \> echo 'build app-a' (re) @@ -47,7 +47,7 @@ Setup \xe2\x80\xa2 Packages in scope: app-a (esc) \xe2\x80\xa2 Running build in 1 packages (esc) \xe2\x80\xa2 Remote caching disabled (esc) - app-a:build: cache hit, replaying logs 906851cd5c1e12d4 + app-a:build: cache hit, replaying logs a1cf9d257ab9b1bf app-a:build: app-a:build: > build app-a:build: > echo 'build app-a' diff --git a/turborepo-tests/integration/tests/run-logging/verbosity.t b/turborepo-tests/integration/tests/run-logging/verbosity.t index 00f2bd8555c11..8aa7009b0a4d3 100644 --- a/turborepo-tests/integration/tests/run-logging/verbosity.t +++ b/turborepo-tests/integration/tests/run-logging/verbosity.t @@ -8,7 +8,7 @@ Verbosity level 1 \xe2\x80\xa2 Packages in scope: util (esc) \xe2\x80\xa2 Running build in 1 packages (esc) \xe2\x80\xa2 Remote caching disabled (esc) - util:build: cache bypass, force executing 76ab904c7ecb2d51 + util:build: cache bypass, force executing 12af4a2f5c5af4e1 util:build: util:build: > build util:build: > echo 'building' @@ -24,7 +24,7 @@ Verbosity level 1 \xe2\x80\xa2 Packages in scope: util (esc) \xe2\x80\xa2 Running build in 1 packages (esc) \xe2\x80\xa2 Remote caching disabled (esc) - util:build: cache bypass, force executing 76ab904c7ecb2d51 + util:build: cache bypass, force executing 12af4a2f5c5af4e1 util:build: util:build: > build util:build: > echo 'building' @@ -44,8 +44,14 @@ Verbosity level 2 [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::shim: No local turbo binary found at: .* (re) [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::shim: Running command as global turbo (re) [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::cli: pkg_inference_root set to "" (re) - [-0-9:.TWZ+]+ \[DEBUG] turbo: Found go binary at "[\-\w\/]+" (re) - [-0-9:.TWZ+]+ \[DEBUG] turbo: build tag: (go|rust) (re) + [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::run::global_hash: global hash env vars \[] (re) + [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::run::global_hash: external deps hash: 459c029558afe716 (re) + [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::run::scope::filter: Using as a basis for selecting packages (re) + [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::task_hash: task hash env vars for util:build (re) + vars: \[] (re) + [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::task_graph::visitor: task util#build hash is 12af4a2f5c5af4e1 (re) + [-0-9:.TWZ+]+ \[DEBUG] turbo: Found go binary at "[\-\w\/\.]+" (re) + [-0-9:.TWZ+]+ \[DEBUG] turbo: build tag: rust (re) [-0-9:.TWZ+]+ \[INFO] turbo: skipping turbod since we appear to be in a non-interactive context (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: filter patterns: patterns=\["util"] (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: Parsed selector: selector="&{includeDependencies:false matchDependencies:false includeDependents:false exclude:false excludeSelf:false followProdDepsOnly:false parentDir: namePattern:util fromRef: toRefOverride: raw:util}" (re) @@ -55,15 +61,16 @@ Verbosity level 2 [-0-9:.TWZ+]+ \[DEBUG] turbo: Filtered packages: cherryPickedPackages=map\[] walkedDependencies=map\[] walkedDependents=map\[] walkedDependentsDependencies=map\[] (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: filtered packages: packages=map\[util:util] (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: global hash env vars: vars=\[] (re) - [-0-9:.TWZ+]+ \[DEBUG] turbo: global hash: value=160d658c9c48fcd3 (re) - [-0-9:.TWZ+]+ |[DEBUG] turbo: local cache folder: path="" (re) + [-0-9:.TWZ+]+ \[DEBUG] turbo: global hash: value=fe3b3e304bbcc4ea (re) + [-0-9:.TWZ+]+ \[DEBUG] turbo: global hash matches between Rust and Go (re) + [-0-9:.TWZ+]+ \[DEBUG] turbo: local cache folder: path="" (re) \xe2\x80\xa2 Packages in scope: util (esc) \xe2\x80\xa2 Running build in 1 packages (esc) \xe2\x80\xa2 Remote caching disabled (esc) [-0-9:.TWZ+]+ \[DEBUG] turbo: task hash env vars for util:build: vars=\[] (re) [-0-9:.TWZ+]+ \[DEBUG] turbo.: start (re) - [-0-9:.TWZ+]+ \[DEBUG] turbo: task hash: value=76ab904c7ecb2d51 (re) - util:build: cache bypass, force executing 76ab904c7ecb2d51 + [-0-9:.TWZ+]+ \[DEBUG] turbo: task hash: value=12af4a2f5c5af4e1 (re) + util:build: cache bypass, force executing 12af4a2f5c5af4e1 util:build: util:build: > build util:build: > echo 'building' @@ -71,6 +78,7 @@ Verbosity level 2 util:build: building [-0-9:.TWZ+]+ \[DEBUG] turbo.: caching output: outputs="{\[packages/util/.turbo/turbo-build.log] \[]}" (re) [-0-9:.TWZ+]+ \[DEBUG] turbo.: done: status=complete duration=[\.0-9]+m?s (re) + [-0-9:.TWZ+]+ \[DEBUG] turbo: task hashes match (re) Tasks: 1 successful, 1 total Cached: 0 cached, 1 total @@ -83,8 +91,14 @@ Verbosity level 2 [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::shim: No local turbo binary found at: .* (re) [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::shim: Running command as global turbo (re) [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::cli: pkg_inference_root set to "" (re) - [-0-9:.TWZ+]+ \[DEBUG] turbo: Found go binary at "[\-\w\/]+" (re) - [-0-9:.TWZ+]+ \[DEBUG] turbo: build tag: (go|rust) (re) + [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::run::global_hash: global hash env vars \[] (re) + [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::run::global_hash: external deps hash: 459c029558afe716 (re) + [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::run::scope::filter: Using as a basis for selecting packages (re) + [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::task_hash: task hash env vars for util:build (re) + vars: [] + [-0-9:.TWZ+]+ \[DEBUG] turborepo_lib::task_graph::visitor: task util#build hash is 12af4a2f5c5af4e1 (re) + [-0-9:.TWZ+]+ \[DEBUG] turbo: Found go binary at "[\-\w\/\.]+" (re) + [-0-9:.TWZ+]+ \[DEBUG] turbo: build tag: rust (re) [-0-9:.TWZ+]+ \[INFO] turbo: skipping turbod since we appear to be in a non-interactive context (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: filter patterns: patterns=\["util"] (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: Parsed selector: selector="&{includeDependencies:false matchDependencies:false includeDependents:false exclude:false excludeSelf:false followProdDepsOnly:false parentDir: namePattern:util fromRef: toRefOverride: raw:util}" (re) @@ -94,15 +108,16 @@ Verbosity level 2 [-0-9:.TWZ+]+ \[DEBUG] turbo: Filtered packages: cherryPickedPackages=map\[] walkedDependencies=map\[] walkedDependents=map\[] walkedDependentsDependencies=map\[] (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: filtered packages: packages=map\[util:util] (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: global hash env vars: vars=\[] (re) - [-0-9:.TWZ+]+ \[DEBUG] turbo: global hash: value=160d658c9c48fcd3 (re) + [-0-9:.TWZ+]+ \[DEBUG] turbo: global hash: value=fe3b3e304bbcc4ea (re) + [-0-9:.TWZ+]+ \[DEBUG] turbo: global hash matches between Rust and Go (re) [-0-9:.TWZ+]+ \[DEBUG] turbo: local cache folder: path="" (re) \xe2\x80\xa2 Packages in scope: util (esc) \xe2\x80\xa2 Running build in 1 packages (esc) \xe2\x80\xa2 Remote caching disabled (esc) [-0-9:.TWZ+]+ \[DEBUG] turbo: task hash env vars for util:build: vars=\[] (re) [-0-9:.TWZ+]+ \[DEBUG] turbo.: start (re) - [-0-9:.TWZ+]+ \[DEBUG] turbo: task hash: value=76ab904c7ecb2d51 (re) - util:build: cache bypass, force executing 76ab904c7ecb2d51 + [-0-9:.TWZ+]+ \[DEBUG] turbo: task hash: value=12af4a2f5c5af4e1 (re) + util:build: cache bypass, force executing 12af4a2f5c5af4e1 util:build: util:build: > build util:build: > echo 'building' @@ -110,6 +125,7 @@ Verbosity level 2 util:build: building [-0-9:.TWZ+]+ \[DEBUG] turbo.: caching output: outputs="{\[packages/util/.turbo/turbo-build.log] \[]}" (re) [-0-9:.TWZ+]+ \[DEBUG] turbo.: done: status=complete duration=[\.0-9]+m?s (re) + [-0-9:.TWZ+]+ \[DEBUG] turbo: task hashes match (re) Tasks: 1 successful, 1 total Cached: 0 cached, 1 total diff --git a/turborepo-tests/integration/tests/run-summary/discovery.t b/turborepo-tests/integration/tests/run-summary/discovery.t index 6d7511819d34a..08ec1a1308e44 100644 --- a/turborepo-tests/integration/tests/run-summary/discovery.t +++ b/turborepo-tests/integration/tests/run-summary/discovery.t @@ -7,7 +7,7 @@ Setup \xe2\x80\xa2 Packages in scope: my-app (esc) \xe2\x80\xa2 Running build in 1 packages (esc) \xe2\x80\xa2 Remote caching disabled (esc) - my-app:build: cache miss, executing 0d1e6ee2c143211c + my-app:build: cache miss, executing 0cd306aa8e337d8a my-app:build: my-app:build: > build my-app:build: > echo 'building' diff --git a/turborepo-tests/integration/tests/run-summary/error.t b/turborepo-tests/integration/tests/run-summary/error.t index 86dffc2f13c6d..505d606d94ab5 100644 --- a/turborepo-tests/integration/tests/run-summary/error.t +++ b/turborepo-tests/integration/tests/run-summary/error.t @@ -33,12 +33,12 @@ Validate that we got a full task summary for the failed task with an error in .e "taskId": "my-app#maybefails", "task": "maybefails", "package": "my-app", - "hash": "7d733e4a2348bbc9", + "hash": "4c3e453c65e743da", "inputs": { ".env.local": "e69de29bb2d1d6434b8b29ae775ad8c2e48c5391", "package.json": "6bcf57fd6ff30d1a6f40ad8d8d08e8b940fc7e3b" }, - "hashOfExternalDependencies": "ccab0b28617f1f56", + "hashOfExternalDependencies": "459c029558afe716", "cache": { "local": false, "remote": false, diff --git a/turborepo-tests/integration/tests/run-summary/monorepo.t b/turborepo-tests/integration/tests/run-summary/monorepo.t index 52262fe590f71..fca419328d7c5 100644 --- a/turborepo-tests/integration/tests/run-summary/monorepo.t +++ b/turborepo-tests/integration/tests/run-summary/monorepo.t @@ -89,7 +89,7 @@ Setup "someargs" ] $ echo $FIRST_APP_BUILD | jq '.hashOfExternalDependencies' - "ccab0b28617f1f56" + "459c029558afe716" $ echo $FIRST_APP_BUILD | jq '.expandedOutputs' [ "apps/my-app/.turbo/turbo-build.log" diff --git a/turborepo-tests/integration/tests/run/continue.t b/turborepo-tests/integration/tests/run/continue.t index 4af9a97d8ff78..ad776394e2449 100644 --- a/turborepo-tests/integration/tests/run/continue.t +++ b/turborepo-tests/integration/tests/run/continue.t @@ -6,7 +6,7 @@ Run without --continue \xe2\x80\xa2 Packages in scope: my-app, other-app, some-lib (esc) \xe2\x80\xa2 Running build in 3 packages (esc) \xe2\x80\xa2 Remote caching disabled (esc) - some-lib:build: cache miss, executing 07e73f626f2c6e2c + some-lib:build: cache miss, executing 315d7d07f0442d0f some-lib:build: some-lib:build: > build some-lib:build: > exit 2 @@ -14,9 +14,9 @@ Run without --continue some-lib:build: npm ERR! Lifecycle script `build` failed with error: some-lib:build: npm ERR! Error: command failed some-lib:build: npm ERR! in workspace: some-lib - some-lib:build: npm ERR! at location: (.*)/apps/some-lib (re) - some-lib:build: ERROR: command finished with error: command \((.*)/apps/some-lib\) npm run build exited \(1\) (re) - some-lib#build: command \((.*)/apps/some-lib\) npm run build exited \(1\) (re) + some-lib:build: npm ERR! at location: (.*)\/apps\/some-lib (re) + some-lib:build: ERROR: command finished with error: command \((.*)\/apps\/some-lib\) npm run build exited \(1\) (re) + some-lib#build: command \(.*\/apps\/some-lib\) npm run build exited \(1\) (re) Tasks: 0 successful, 1 total Cached: 0 cached, 1 total @@ -26,12 +26,13 @@ Run without --continue ERROR run failed: command exited (1) [1] + Run without --continue, and with only errors. $ ${TURBO} build --output-logs=errors-only \xe2\x80\xa2 Packages in scope: my-app, other-app, some-lib (esc) \xe2\x80\xa2 Running build in 3 packages (esc) \xe2\x80\xa2 Remote caching disabled (esc) - some-lib:build: cache miss, executing 07e73f626f2c6e2c + some-lib:build: cache miss, executing 315d7d07f0442d0f some-lib:build: some-lib:build: > build some-lib:build: > exit 2 @@ -39,9 +40,9 @@ Run without --continue, and with only errors. some-lib:build: npm ERR! Lifecycle script `build` failed with error: some-lib:build: npm ERR! Error: command failed some-lib:build: npm ERR! in workspace: some-lib - some-lib:build: npm ERR! at location: (.*)/apps/some-lib (re) - some-lib:build: ERROR: command finished with error: command \((.*)/apps/some-lib\) npm run build exited \(1\) (re) - some-lib#build: command \((.*)/apps/some-lib\) npm run build exited \(1\) (re) + some-lib:build: npm ERR! at location: (.*)\/apps\/some-lib (re) + some-lib:build: ERROR: command finished with error: command \((.*)\/apps\/some-lib\) npm run build exited \(1\) (re) + some-lib#build: command \(.*\) npm run build exited \(1\) (re) Tasks: 0 successful, 1 total Cached: 0 cached, 1 total @@ -56,7 +57,7 @@ Run with --continue \xe2\x80\xa2 Packages in scope: my-app, other-app, some-lib (esc) \xe2\x80\xa2 Running build in 3 packages (esc) \xe2\x80\xa2 Remote caching disabled (esc) - some-lib:build: cache miss, executing 07e73f626f2c6e2c + some-lib:build: cache miss, executing 315d7d07f0442d0f some-lib:build: some-lib:build: > build some-lib:build: > exit 2 @@ -66,7 +67,7 @@ Run with --continue some-lib:build: npm ERR! in workspace: some-lib some-lib:build: npm ERR! at location: (.*)/apps/some-lib (re) some-lib:build: command finished with error, but continuing... - other-app:build: cache miss, executing 2f40356243966a58 + other-app:build: cache miss, executing 3334feeb74f3f09d other-app:build: other-app:build: > build other-app:build: > exit 3 @@ -86,3 +87,4 @@ Run with --continue ERROR run failed: command exited (1) [1] + diff --git a/turborepo-tests/integration/tests/run/force.t b/turborepo-tests/integration/tests/run/force.t index d6fad68590e7a..060d60bcf7672 100644 --- a/turborepo-tests/integration/tests/run/force.t +++ b/turborepo-tests/integration/tests/run/force.t @@ -25,7 +25,7 @@ baseline to generate cache \xe2\x80\xa2 Packages in scope: my-app (esc) \xe2\x80\xa2 Running build in 1 packages (esc) \xe2\x80\xa2 Remote caching disabled (esc) - my-app:build: cache miss, executing 0d1e6ee2c143211c + my-app:build: cache miss, executing 0cd306aa8e337d8a Tasks: 1 successful, 1 total Cached: 0 cached, 1 total @@ -37,7 +37,7 @@ baseline to generate cache \xe2\x80\xa2 Packages in scope: my-app (esc) \xe2\x80\xa2 Running build in 1 packages (esc) \xe2\x80\xa2 Remote caching disabled (esc) - my-app:build: cache bypass, force executing 0d1e6ee2c143211c + my-app:build: cache bypass, force executing 0cd306aa8e337d8a Tasks: 1 successful, 1 total Cached: 0 cached, 1 total @@ -48,7 +48,7 @@ baseline to generate cache \xe2\x80\xa2 Packages in scope: my-app (esc) \xe2\x80\xa2 Running build in 1 packages (esc) \xe2\x80\xa2 Remote caching disabled (esc) - my-app:build: cache bypass, force executing 0d1e6ee2c143211c + my-app:build: cache bypass, force executing 0cd306aa8e337d8a Tasks: 1 successful, 1 total Cached: 0 cached, 1 total @@ -59,7 +59,7 @@ baseline to generate cache \xe2\x80\xa2 Packages in scope: my-app (esc) \xe2\x80\xa2 Running build in 1 packages (esc) \xe2\x80\xa2 Remote caching disabled (esc) - my-app:build: cache hit, suppressing logs 0d1e6ee2c143211c + my-app:build: cache hit, suppressing logs 0cd306aa8e337d8a Tasks: 1 successful, 1 total Cached: 1 cached, 1 total @@ -70,7 +70,7 @@ baseline to generate cache \xe2\x80\xa2 Packages in scope: my-app (esc) \xe2\x80\xa2 Running build in 1 packages (esc) \xe2\x80\xa2 Remote caching disabled (esc) - my-app:build: cache bypass, force executing 0d1e6ee2c143211c + my-app:build: cache bypass, force executing 0cd306aa8e337d8a Tasks: 1 successful, 1 total Cached: 0 cached, 1 total @@ -82,7 +82,7 @@ baseline to generate cache \xe2\x80\xa2 Packages in scope: my-app (esc) \xe2\x80\xa2 Running build in 1 packages (esc) \xe2\x80\xa2 Remote caching disabled (esc) - my-app:build: cache hit, suppressing logs 0d1e6ee2c143211c + my-app:build: cache hit, suppressing logs 0cd306aa8e337d8a Tasks: 1 successful, 1 total Cached: 1 cached, 1 total @@ -93,7 +93,7 @@ baseline to generate cache \xe2\x80\xa2 Packages in scope: my-app (esc) \xe2\x80\xa2 Running build in 1 packages (esc) \xe2\x80\xa2 Remote caching disabled (esc) - my-app:build: cache bypass, force executing 0d1e6ee2c143211c + my-app:build: cache bypass, force executing 0cd306aa8e337d8a Tasks: 1 successful, 1 total Cached: 0 cached, 1 total @@ -104,7 +104,7 @@ baseline to generate cache \xe2\x80\xa2 Packages in scope: my-app (esc) \xe2\x80\xa2 Running build in 1 packages (esc) \xe2\x80\xa2 Remote caching disabled (esc) - my-app:build: cache hit, suppressing logs 0d1e6ee2c143211c + my-app:build: cache hit, suppressing logs 0cd306aa8e337d8a Tasks: 1 successful, 1 total Cached: 1 cached, 1 total @@ -115,7 +115,7 @@ baseline to generate cache \xe2\x80\xa2 Packages in scope: my-app (esc) \xe2\x80\xa2 Running build in 1 packages (esc) \xe2\x80\xa2 Remote caching disabled (esc) - my-app:build: cache bypass, force executing 0d1e6ee2c143211c + my-app:build: cache bypass, force executing 0cd306aa8e337d8a Tasks: 1 successful, 1 total Cached: 0 cached, 1 total @@ -127,7 +127,7 @@ baseline to generate cache \xe2\x80\xa2 Packages in scope: my-app (esc) \xe2\x80\xa2 Running build in 1 packages (esc) \xe2\x80\xa2 Remote caching disabled (esc) - my-app:build: cache hit, suppressing logs 0d1e6ee2c143211c + my-app:build: cache hit, suppressing logs 0cd306aa8e337d8a Tasks: 1 successful, 1 total Cached: 1 cached, 1 total @@ -138,7 +138,7 @@ baseline to generate cache \xe2\x80\xa2 Packages in scope: my-app (esc) \xe2\x80\xa2 Running build in 1 packages (esc) \xe2\x80\xa2 Remote caching disabled (esc) - my-app:build: cache bypass, force executing 0d1e6ee2c143211c + my-app:build: cache bypass, force executing 0cd306aa8e337d8a Tasks: 1 successful, 1 total Cached: 0 cached, 1 total @@ -149,7 +149,7 @@ baseline to generate cache \xe2\x80\xa2 Packages in scope: my-app (esc) \xe2\x80\xa2 Running build in 1 packages (esc) \xe2\x80\xa2 Remote caching disabled (esc) - my-app:build: cache hit, suppressing logs 0d1e6ee2c143211c + my-app:build: cache hit, suppressing logs 0cd306aa8e337d8a Tasks: 1 successful, 1 total Cached: 1 cached, 1 total @@ -160,7 +160,7 @@ baseline to generate cache \xe2\x80\xa2 Packages in scope: my-app (esc) \xe2\x80\xa2 Running build in 1 packages (esc) \xe2\x80\xa2 Remote caching disabled (esc) - my-app:build: cache bypass, force executing 0d1e6ee2c143211c + my-app:build: cache bypass, force executing 0cd306aa8e337d8a Tasks: 1 successful, 1 total Cached: 0 cached, 1 total diff --git a/turborepo-tests/integration/tests/run/missing-tasks.t b/turborepo-tests/integration/tests/run/missing-tasks.t index 248eff5645add..216425c6e7c35 100644 --- a/turborepo-tests/integration/tests/run/missing-tasks.t +++ b/turborepo-tests/integration/tests/run/missing-tasks.t @@ -4,41 +4,25 @@ Setup # Running non-existent tasks errors $ ${TURBO} run doesnotexist - ERROR run failed: error preparing engine: Could not find the following tasks in project: doesnotexist - Turbo error: error preparing engine: Could not find the following tasks in project: doesnotexist + Error: Could not find the following tasks in project: doesnotexist [1] # Multiple non-existent tasks also error $ ${TURBO} run doesnotexist alsono - ERROR run failed: error preparing engine: Could not find the following tasks in project: alsono, doesnotexist - Turbo error: error preparing engine: Could not find the following tasks in project: alsono, doesnotexist + Error: Could not find the following tasks in project: alsono, doesnotexist [1] # One good and one bad task does not error $ ${TURBO} run build doesnotexist - ERROR run failed: error preparing engine: Could not find the following tasks in project: doesnotexist - Turbo error: error preparing engine: Could not find the following tasks in project: doesnotexist + Error: Could not find the following tasks in project: doesnotexist [1] # Bad command $ ${TURBO} run something --dry - root task something (turbo run build) looks like it invokes turbo and might cause a loop - ERROR run failed: errors occurred during dry-run graph traversal - Turbo error: errors occurred during dry-run graph traversal + Error: root task //#something (turbo run build) looks like it invokes turbo and might cause a loop [1] # Bad command $ ${TURBO} run something - \xe2\x80\xa2 Packages in scope: //, another, my-app, util (esc) - \xe2\x80\xa2 Running something in 4 packages (esc) - \xe2\x80\xa2 Remote caching disabled (esc) - root task something (turbo run build) looks like it invokes turbo and might cause a loop - - No tasks were executed as part of this run. - - Tasks: 0 successful, 0 total - Cached: 0 cached, 0 total - Time:\s*[\.0-9]+m?s (re) - - ERROR run failed: command exited (1) + Error: root task //#something (turbo run build) looks like it invokes turbo and might cause a loop [1] diff --git a/turborepo-tests/integration/tests/run/one-script-error.t b/turborepo-tests/integration/tests/run/one-script-error.t index 60737526468ba..ee7074d4e1a32 100644 --- a/turborepo-tests/integration/tests/run/one-script-error.t +++ b/turborepo-tests/integration/tests/run/one-script-error.t @@ -8,13 +8,13 @@ Note that npm reports any failed script as exit code 1, even though we "exit 2" \xe2\x80\xa2 Packages in scope: my-app (esc) \xe2\x80\xa2 Running error in 1 packages (esc) \xe2\x80\xa2 Remote caching disabled (esc) - my-app:okay: cache miss, executing 9365dd2ae80cb6fb + my-app:okay: cache miss, executing ec30e849f14d9045 my-app:okay: my-app:okay: > okay my-app:okay: > echo 'working' my-app:okay: my-app:okay: working - my-app:error: cache miss, executing b34c6a3e57e8688c + my-app:error: cache miss, executing 89701fb53e561a07 my-app:error: my-app:error: > error my-app:error: > exit 2 @@ -39,13 +39,13 @@ Make sure error isn't cached \xe2\x80\xa2 Packages in scope: my-app (esc) \xe2\x80\xa2 Running error in 1 packages (esc) \xe2\x80\xa2 Remote caching disabled (esc) - my-app:okay: cache hit, replaying logs 9365dd2ae80cb6fb + my-app:okay: cache hit, replaying logs ec30e849f14d9045 my-app:okay: my-app:okay: > okay my-app:okay: > echo 'working' my-app:okay: my-app:okay: working - my-app:error: cache miss, executing b34c6a3e57e8688c + my-app:error: cache miss, executing 89701fb53e561a07 my-app:error: my-app:error: > error my-app:error: > exit 2 @@ -70,13 +70,13 @@ Make sure error code isn't swallowed with continue \xe2\x80\xa2 Packages in scope: my-app (esc) \xe2\x80\xa2 Running okay2 in 1 packages (esc) \xe2\x80\xa2 Remote caching disabled (esc) - my-app:okay: cache hit, replaying logs 9365dd2ae80cb6fb + my-app:okay: cache hit, replaying logs ec30e849f14d9045 my-app:okay: my-app:okay: > okay my-app:okay: > echo 'working' my-app:okay: my-app:okay: working - my-app:error: cache miss, executing b34c6a3e57e8688c + my-app:error: cache miss, executing 89701fb53e561a07 my-app:error: my-app:error: > error my-app:error: > exit 2 @@ -86,7 +86,7 @@ Make sure error code isn't swallowed with continue my-app:error: npm ERR! in workspace: my-app my-app:error: npm ERR! at location: .*apps/my-app (re) my-app:error: command finished with error, but continuing... - my-app:okay2: cache miss, executing e83cf1a4089996da + my-app:okay2: cache miss, executing c5e440ac76d920b4 my-app:okay2: my-app:okay2: > okay2 my-app:okay2: > echo 'working' diff --git a/turborepo-tests/integration/tests/single_package/dry-run.t b/turborepo-tests/integration/tests/single_package/dry-run.t index f5638e8fb8cb9..1424d9b575472 100644 --- a/turborepo-tests/integration/tests/single_package/dry-run.t +++ b/turborepo-tests/integration/tests/single_package/dry-run.t @@ -19,7 +19,7 @@ Check Tasks to Run build Task = build - Hash = d2295def33764d46 + Hash = f9360c1870434eb2 Cached (Local) = false Cached (Remote) = false Command = echo 'building' > foo diff --git a/turborepo-tests/integration/tests/single_package/no-config.t b/turborepo-tests/integration/tests/single_package/no-config.t index 6215e714a5b8e..855dc09a1fa7c 100644 --- a/turborepo-tests/integration/tests/single_package/no-config.t +++ b/turborepo-tests/integration/tests/single_package/no-config.t @@ -21,7 +21,7 @@ Check Tasks to Run build Task = build - Hash = a6461c1683e4f102 + Hash = 3f02bc73f1ab0cce Cached (Local) = false Cached (Remote) = false Command = echo 'building' > foo @@ -53,7 +53,7 @@ Run real once $ ${TURBO} run build \xe2\x80\xa2 Running build (esc) \xe2\x80\xa2 Remote caching disabled (esc) - build: cache bypass, force executing a6461c1683e4f102 + build: cache bypass, force executing 3f02bc73f1ab0cce build: build: > build build: > echo 'building' > foo @@ -67,7 +67,7 @@ Run a second time, verify no caching because there is no config $ ${TURBO} run build --single-package \xe2\x80\xa2 Running build (esc) \xe2\x80\xa2 Remote caching disabled (esc) - build: cache bypass, force executing a6461c1683e4f102 + build: cache bypass, force executing 3f02bc73f1ab0cce build: build: > build build: > echo 'building' > foo diff --git a/turborepo-tests/integration/tests/single_package/run-yarn.t b/turborepo-tests/integration/tests/single_package/run-yarn.t index 63f9d794c2cfb..52c48174eb578 100644 --- a/turborepo-tests/integration/tests/single_package/run-yarn.t +++ b/turborepo-tests/integration/tests/single_package/run-yarn.t @@ -9,7 +9,7 @@ Check $ ${TURBO} run build \xe2\x80\xa2 Running build (esc) \xe2\x80\xa2 Remote caching disabled (esc) - build: cache miss, executing 95dd1b2d0d9ded60 + build: cache miss, executing d5baee717813ef41 build: yarn run v1.22.17 build: warning package.json: No license field build: $ echo 'building' > foo @@ -23,7 +23,7 @@ Check $ ${TURBO} run build \xe2\x80\xa2 Running build (esc) \xe2\x80\xa2 Remote caching disabled (esc) - build: cache hit, replaying logs 95dd1b2d0d9ded60 + build: cache hit, replaying logs d5baee717813ef41 build: yarn run v1.22.17 build: warning package.json: No license field build: $ echo 'building' > foo diff --git a/turborepo-tests/integration/tests/single_package/run.t b/turborepo-tests/integration/tests/single_package/run.t index bac7e01ceb2b6..75754449d7b6a 100644 --- a/turborepo-tests/integration/tests/single_package/run.t +++ b/turborepo-tests/integration/tests/single_package/run.t @@ -6,7 +6,7 @@ Check $ ${TURBO} run build \xe2\x80\xa2 Running build (esc) \xe2\x80\xa2 Remote caching disabled (esc) - build: cache miss, executing d2295def33764d46 + build: cache miss, executing f9360c1870434eb2 build: build: > build build: > echo 'building' > foo @@ -23,7 +23,7 @@ Run a second time, verify caching works because there is a config $ ${TURBO} run build --single-package \xe2\x80\xa2 Running build (esc) \xe2\x80\xa2 Remote caching disabled (esc) - build: cache hit, replaying logs d2295def33764d46 + build: cache hit, replaying logs f9360c1870434eb2 build: build: > build build: > echo 'building' > foo diff --git a/turborepo-tests/integration/tests/single_package/with-deps-dry-run.t b/turborepo-tests/integration/tests/single_package/with-deps-dry-run.t index 1efb2f52a6f68..f163b2ddc1a69 100644 --- a/turborepo-tests/integration/tests/single_package/with-deps-dry-run.t +++ b/turborepo-tests/integration/tests/single_package/with-deps-dry-run.t @@ -19,7 +19,7 @@ Check Tasks to Run build Task = build - Hash = d6b8b065382193a4 + Hash = cd720138f792fbca Cached (Local) = false Cached (Remote) = false Command = echo 'building' > foo @@ -38,7 +38,7 @@ Check Framework = test Task = test - Hash = 1dca8c4431a90e36 + Hash = 118e4fe7f2e841be Cached (Local) = false Cached (Remote) = false Command = [[ ( -f foo ) && $(cat foo) == 'building' ]] diff --git a/turborepo-tests/integration/tests/single_package/with-deps-run.t b/turborepo-tests/integration/tests/single_package/with-deps-run.t index bba27dab55723..2947b5c0dc4d7 100644 --- a/turborepo-tests/integration/tests/single_package/with-deps-run.t +++ b/turborepo-tests/integration/tests/single_package/with-deps-run.t @@ -6,12 +6,12 @@ Check $ ${TURBO} run test \xe2\x80\xa2 Running test (esc) \xe2\x80\xa2 Remote caching disabled (esc) - build: cache miss, executing d6b8b065382193a4 + build: cache miss, executing cd720138f792fbca build: build: > build build: > echo 'building' > foo build: - test: cache miss, executing 1dca8c4431a90e36 + test: cache miss, executing 118e4fe7f2e841be test: test: > test test: > [[ ( -f foo ) && $(cat foo) == 'building' ]] @@ -25,12 +25,12 @@ Run a second time, verify caching works because there is a config $ ${TURBO} run test \xe2\x80\xa2 Running test (esc) \xe2\x80\xa2 Remote caching disabled (esc) - build: cache hit, replaying logs d6b8b065382193a4 + build: cache hit, replaying logs cd720138f792fbca build: build: > build build: > echo 'building' > foo build: - test: cache hit, replaying logs 1dca8c4431a90e36 + test: cache hit, replaying logs 118e4fe7f2e841be test: test: > test test: > [[ ( -f foo ) && $(cat foo) == 'building' ]] @@ -44,8 +44,8 @@ Run with --output-logs=hash-only $ ${TURBO} run test --output-logs=hash-only \xe2\x80\xa2 Running test (esc) \xe2\x80\xa2 Remote caching disabled (esc) - build: cache hit, suppressing logs d6b8b065382193a4 - test: cache hit, suppressing logs 1dca8c4431a90e36 + build: cache hit, suppressing logs cd720138f792fbca + test: cache hit, suppressing logs 118e4fe7f2e841be Tasks: 2 successful, 2 total Cached: 2 cached, 2 total diff --git a/turborepo-tests/integration/tests/task-dependencies/complex.t b/turborepo-tests/integration/tests/task-dependencies/complex.t index d7372d14c8d88..0734eb4007e0a 100644 --- a/turborepo-tests/integration/tests/task-dependencies/complex.t +++ b/turborepo-tests/integration/tests/task-dependencies/complex.t @@ -34,14 +34,12 @@ We can scope the run to specific packages Can't depend on unknown tasks $ ${TURBO} run build2 - ERROR run failed: error preparing engine: Could not find "app-a#custom" in root turbo.json or "app-a" workspace - Turbo error: error preparing engine: Could not find "app-a#custom" in root turbo.json or "app-a" workspace + Error: Could not find "app-a#custom" in root turbo.json or "custom" in workspace [1] Can't depend on tasks from unknown packages $ ${TURBO} run build3 - ERROR run failed: error preparing engine: Could not find workspace "unknown" from task "unknown#custom" in project - Turbo error: error preparing engine: Could not find workspace "unknown" from task "unknown#custom" in project + Error: Could not find workspace "unknown" from task "unknown#custom" in project [1] @@ -101,8 +99,5 @@ Check that --only only runs leaf tasks Can't depend on itself $ ${TURBO} run build4 - ERROR run failed: error preparing engine: Invalid task dependency graph: - .*#build4 depends on itself (re) - Turbo error: error preparing engine: Invalid task dependency graph: - .*#build4 depends on itself (re) + Error: (lib-a|lib-b|lib-c|lib-d|app-a|app-b)#build4 depends on itself (re) [1] diff --git a/turborepo-tests/integration/tests/task-dependencies/overwriting.t b/turborepo-tests/integration/tests/task-dependencies/overwriting.t index a005f1b235045..f4872fe715323 100644 --- a/turborepo-tests/integration/tests/task-dependencies/overwriting.t +++ b/turborepo-tests/integration/tests/task-dependencies/overwriting.t @@ -12,7 +12,7 @@ Test # workspace-a#generate ran $ cat tmp.log | grep "workspace-a:generate" - workspace-a:generate: cache miss, executing 7c3d81e9520b4fa7 + workspace-a:generate: cache miss, executing 46f3f1e710a2d0b8 workspace-a:generate: workspace-a:generate: > generate workspace-a:generate: > echo 'generate workspace-a' @@ -20,7 +20,7 @@ Test workspace-a:generate: generate workspace-a workspace-a#build ran $ cat tmp.log | grep "workspace-a:build" - workspace-a:build: cache miss, executing 5a31557b4fd4660a + workspace-a:build: cache miss, executing a9fb13e14871df7f workspace-a:build: workspace-a:build: > build workspace-a:build: > echo 'build workspace-a' @@ -33,7 +33,7 @@ workspace-b#generate DID NOT run workspace-b#build ran $ cat tmp.log | grep "workspace-b:build" - workspace-b:build: cache miss, executing b6dfa3bda3ea6058 + workspace-b:build: cache miss, executing 51cfb4e7af26bc7e workspace-b:build: workspace-b:build: > build workspace-b:build: > echo 'build workspace-b' diff --git a/turborepo-tests/integration/tests/task-dependencies/topological.t b/turborepo-tests/integration/tests/task-dependencies/topological.t index a597500d34ddd..f4d1ed93544a3 100644 --- a/turborepo-tests/integration/tests/task-dependencies/topological.t +++ b/turborepo-tests/integration/tests/task-dependencies/topological.t @@ -7,13 +7,13 @@ Check my-app#build output \xe2\x80\xa2 Packages in scope: //, my-app, util (esc) \xe2\x80\xa2 Running build in 3 packages (esc) \xe2\x80\xa2 Remote caching disabled (esc) - util:build: cache miss, executing 15afa8f5e464aba7 + util:build: cache miss, executing ee9685345ba46dba util:build: util:build: > build util:build: > echo 'building' util:build: util:build: building - my-app:build: cache miss, executing 3ad0e8134e587278 + my-app:build: cache miss, executing da832cec52fed1bc my-app:build: my-app:build: > build my-app:build: > echo 'building' diff --git a/turborepo-tests/integration/tests/task-dependencies/workspace-tasks.t b/turborepo-tests/integration/tests/task-dependencies/workspace-tasks.t index 29da443fc7cbb..75572b798fa5c 100644 --- a/turborepo-tests/integration/tests/task-dependencies/workspace-tasks.t +++ b/turborepo-tests/integration/tests/task-dependencies/workspace-tasks.t @@ -37,8 +37,7 @@ Can depend on root tasks Can't depend on a missing root task $ ${TURBO} run build3 --graph - ERROR run failed: error preparing engine: //#not-exists needs an entry in turbo.json before it can be depended on because it is a task run from the root package - Turbo error: error preparing engine: //#not-exists needs an entry in turbo.json before it can be depended on because it is a task run from the root package + Error: //#not-exists needs an entry in turbo.json before it can be depended on because it is a task run from the root package [1] Package tasks can depend on things diff --git a/turborepo-tests/integration/tests/workspace-configs/add-keys.t b/turborepo-tests/integration/tests/workspace-configs/add-keys.t index 5a869b06f116b..ea8f828f2bb18 100644 --- a/turborepo-tests/integration/tests/workspace-configs/add-keys.t +++ b/turborepo-tests/integration/tests/workspace-configs/add-keys.t @@ -15,13 +15,13 @@ Setup \xe2\x80\xa2 Packages in scope: add-keys (esc) \xe2\x80\xa2 Running add-keys-task in 1 packages (esc) \xe2\x80\xa2 Remote caching disabled (esc) - add-keys:add-keys-underlying-task: cache miss, executing 247f839d50093833 + add-keys:add-keys-underlying-task: cache miss, executing ce61e70a3c44f362 add-keys:add-keys-underlying-task: add-keys:add-keys-underlying-task: > add-keys-underlying-task add-keys:add-keys-underlying-task: > echo "running add-keys-underlying-task" add-keys:add-keys-underlying-task: add-keys:add-keys-underlying-task: running add-keys-underlying-task - add-keys:add-keys-task: cache miss, executing be69dcce790fb9c2 + add-keys:add-keys-task: cache miss, executing c99abbaa42c20133 add-keys:add-keys-task: add-keys:add-keys-task: > add-keys-task add-keys:add-keys-task: > echo "running add-keys-task" > out/foo.min.txt @@ -43,13 +43,13 @@ Setup \xe2\x80\xa2 Packages in scope: add-keys (esc) \xe2\x80\xa2 Running add-keys-task in 1 packages (esc) \xe2\x80\xa2 Remote caching disabled (esc) - add-keys:add-keys-underlying-task: cache hit, replaying logs 247f839d50093833 + add-keys:add-keys-underlying-task: cache hit, replaying logs ce61e70a3c44f362 add-keys:add-keys-underlying-task: add-keys:add-keys-underlying-task: > add-keys-underlying-task add-keys:add-keys-underlying-task: > echo "running add-keys-underlying-task" add-keys:add-keys-underlying-task: add-keys:add-keys-underlying-task: running add-keys-underlying-task - add-keys:add-keys-task: cache hit, suppressing logs be69dcce790fb9c2 + add-keys:add-keys-task: cache hit, suppressing logs c99abbaa42c20133 Tasks: 2 successful, 2 total Cached: 2 cached, 2 total @@ -61,13 +61,13 @@ Setup \xe2\x80\xa2 Packages in scope: add-keys (esc) \xe2\x80\xa2 Running add-keys-task in 1 packages (esc) \xe2\x80\xa2 Remote caching disabled (esc) - add-keys:add-keys-underlying-task: cache miss, executing ba66b7cb11224e10 + add-keys:add-keys-underlying-task: cache miss, executing e720ba2c11b9bdc1 add-keys:add-keys-underlying-task: add-keys:add-keys-underlying-task: > add-keys-underlying-task add-keys:add-keys-underlying-task: > echo "running add-keys-underlying-task" add-keys:add-keys-underlying-task: add-keys:add-keys-underlying-task: running add-keys-underlying-task - add-keys:add-keys-task: cache miss, executing 3401db0bece59315 + add-keys:add-keys-task: cache miss, executing 4a904bee3d5a3ed0 add-keys:add-keys-task: add-keys:add-keys-task: > add-keys-task add-keys:add-keys-task: > echo "running add-keys-task" > out/foo.min.txt @@ -82,13 +82,13 @@ Setup \xe2\x80\xa2 Packages in scope: add-keys (esc) \xe2\x80\xa2 Running add-keys-task in 1 packages (esc) \xe2\x80\xa2 Remote caching disabled (esc) - add-keys:add-keys-underlying-task: cache hit, replaying logs ba66b7cb11224e10 + add-keys:add-keys-underlying-task: cache hit, replaying logs e720ba2c11b9bdc1 add-keys:add-keys-underlying-task: add-keys:add-keys-underlying-task: > add-keys-underlying-task add-keys:add-keys-underlying-task: > echo "running add-keys-underlying-task" add-keys:add-keys-underlying-task: add-keys:add-keys-underlying-task: running add-keys-underlying-task - add-keys:add-keys-task: cache miss, executing fc317f95a51a9d63 + add-keys:add-keys-task: cache miss, executing bf8b6c9c088e838a add-keys:add-keys-task: add-keys:add-keys-task: > add-keys-task add-keys:add-keys-task: > echo "running add-keys-task" > out/foo.min.txt diff --git a/turborepo-tests/integration/tests/workspace-configs/add-tasks.t b/turborepo-tests/integration/tests/workspace-configs/add-tasks.t index c4bd6c5a3df69..d89776274c52b 100644 --- a/turborepo-tests/integration/tests/workspace-configs/add-tasks.t +++ b/turborepo-tests/integration/tests/workspace-configs/add-tasks.t @@ -6,7 +6,7 @@ Setup \xe2\x80\xa2 Packages in scope: add-tasks (esc) \xe2\x80\xa2 Running added-task in 1 packages (esc) \xe2\x80\xa2 Remote caching disabled (esc) - add-tasks:added-task: cache miss, executing 968a5fa46f3ecb61 + add-tasks:added-task: cache miss, executing fd13a0b4238f9404 add-tasks:added-task: add-tasks:added-task: > added-task add-tasks:added-task: > echo "running added-task" > out/foo.min.txt diff --git a/turborepo-tests/integration/tests/workspace-configs/bad-json.t b/turborepo-tests/integration/tests/workspace-configs/bad-json.t index e497e2bda691e..a4db236121be9 100644 --- a/turborepo-tests/integration/tests/workspace-configs/bad-json.t +++ b/turborepo-tests/integration/tests/workspace-configs/bad-json.t @@ -10,5 +10,4 @@ Setup $ ${TURBO} run trailing-comma --filter=bad-json > tmp.log 2>&1 [1] $ cat tmp.log - ERROR run failed: error preparing engine: turbo.json: invalid character '}' looking for beginning of object key string - Turbo error: error preparing engine: turbo.json: invalid character '}' looking for beginning of object key string + Error: trailing comma at line 1 column 36 diff --git a/turborepo-tests/integration/tests/workspace-configs/cache.t b/turborepo-tests/integration/tests/workspace-configs/cache.t index 23b5bb9d7735f..3aa187ad00ce9 100644 --- a/turborepo-tests/integration/tests/workspace-configs/cache.t +++ b/turborepo-tests/integration/tests/workspace-configs/cache.t @@ -14,7 +14,7 @@ This test covers: \xe2\x80\xa2 Packages in scope: cached (esc) \xe2\x80\xa2 Running cached-task-1 in 1 packages (esc) \xe2\x80\xa2 Remote caching disabled (esc) - cached:cached-task-1: cache miss, executing c7b2eeeeebe882f4 + cached:cached-task-1: cache miss, executing 57ff173787b1d8fe cached:cached-task-1: cached:cached-task-1: > cached-task-1 cached:cached-task-1: > echo 'cached-task-1' > out/foo.min.txt @@ -39,7 +39,7 @@ This test covers: \xe2\x80\xa2 Packages in scope: cached (esc) \xe2\x80\xa2 Running cached-task-2 in 1 packages (esc) \xe2\x80\xa2 Remote caching disabled (esc) - cached:cached-task-2: cache bypass, force executing e47823a61c0194fe + cached:cached-task-2: cache bypass, force executing 6246dab06d9ba2d5 cached:cached-task-2: cached:cached-task-2: > cached-task-2 cached:cached-task-2: > echo 'cached-task-2' > out/foo.min.txt @@ -61,7 +61,7 @@ no `cache` config in root, cache:false in workspace \xe2\x80\xa2 Packages in scope: cached (esc) \xe2\x80\xa2 Running cached-task-3 in 1 packages (esc) \xe2\x80\xa2 Remote caching disabled (esc) - cached:cached-task-3: cache bypass, force executing 8284eb185db66911 + cached:cached-task-3: cache bypass, force executing eb2e67e273c47f71 cached:cached-task-3: cached:cached-task-3: > cached-task-3 cached:cached-task-3: > echo 'cached-task-3' > out/foo.min.txt @@ -85,7 +85,7 @@ we already have a workspace that doesn't have a config \xe2\x80\xa2 Packages in scope: missing-workspace-config (esc) \xe2\x80\xa2 Running cached-task-4 in 1 packages (esc) \xe2\x80\xa2 Remote caching disabled (esc) - missing-workspace-config:cached-task-4: cache bypass, force executing 632c5a434e281d13 + missing-workspace-config:cached-task-4: cache bypass, force executing 4c78caa1e959eb28 missing-workspace-config:cached-task-4: missing-workspace-config:cached-task-4: > cached-task-4 missing-workspace-config:cached-task-4: > echo 'cached-task-4' > out/foo.min.txt diff --git a/turborepo-tests/integration/tests/workspace-configs/config-change.t b/turborepo-tests/integration/tests/workspace-configs/config-change.t index 41ade7d62ee0d..0eb57047f1bad 100644 --- a/turborepo-tests/integration/tests/workspace-configs/config-change.t +++ b/turborepo-tests/integration/tests/workspace-configs/config-change.t @@ -4,13 +4,13 @@ Setup # 1. First run, check the hash $ ${TURBO} run config-change-task --filter=config-change --dry=json | jq .tasks[0].hash - "a138414497b0dbbc" + "1a2c838455c22b55" 2. Run again and assert task hash stays the same $ ${TURBO} run config-change-task --filter=config-change --dry=json | jq .tasks[0].hash - "a138414497b0dbbc" + "1a2c838455c22b55" 3. Change turbo.json and assert that hash changes $ cp $TARGET_DIR/apps/config-change/turbo-changed.json $TARGET_DIR/apps/config-change/turbo.json $ ${TURBO} run config-change-task --filter=config-change --dry=json | jq .tasks[0].hash - "a79a2200df892f91" + "40af184729e96396" diff --git a/turborepo-tests/integration/tests/workspace-configs/cross-workspace.t b/turborepo-tests/integration/tests/workspace-configs/cross-workspace.t index 7d2d944fef10e..fc968c470e55f 100644 --- a/turborepo-tests/integration/tests/workspace-configs/cross-workspace.t +++ b/turborepo-tests/integration/tests/workspace-configs/cross-workspace.t @@ -5,13 +5,13 @@ Setup \xe2\x80\xa2 Packages in scope: cross-workspace (esc) \xe2\x80\xa2 Running cross-workspace-task in 1 packages (esc) \xe2\x80\xa2 Remote caching disabled (esc) - blank-pkg:cross-workspace-underlying-task: cache miss, executing fa5501f81cccc6c0 + blank-pkg:cross-workspace-underlying-task: cache miss, executing 8598f02672ab1e28 blank-pkg:cross-workspace-underlying-task: blank-pkg:cross-workspace-underlying-task: > cross-workspace-underlying-task blank-pkg:cross-workspace-underlying-task: > echo "cross-workspace-underlying-task from blank-pkg" blank-pkg:cross-workspace-underlying-task: blank-pkg:cross-workspace-underlying-task: cross-workspace-underlying-task from blank-pkg - cross-workspace:cross-workspace-task: cache miss, executing b7d0a03fe61bfe45 + cross-workspace:cross-workspace-task: cache miss, executing 14e179c4728a24ac cross-workspace:cross-workspace-task: cross-workspace:cross-workspace-task: > cross-workspace-task cross-workspace:cross-workspace-task: > echo "cross-workspace-task" diff --git a/turborepo-tests/integration/tests/workspace-configs/invalid-config.t b/turborepo-tests/integration/tests/workspace-configs/invalid-config.t index 3a800aca7ccf8..b9e197c4b5c4a 100644 --- a/turborepo-tests/integration/tests/workspace-configs/invalid-config.t +++ b/turborepo-tests/integration/tests/workspace-configs/invalid-config.t @@ -8,30 +8,22 @@ Errors are shown if we run a task that is misconfigured (invalid-config#build) $ ${TURBO} run build --filter=invalid-config > tmp.log 2>&1 [1] $ cat tmp.log | grep "Invalid turbo.json" - ERROR run failed: error preparing engine: Invalid turbo.json - Turbo error: error preparing engine: Invalid turbo.json + Error: Invalid turbo.json: $ cat tmp.log | grep "invalid-config#build" - "invalid-config#build". Use "build" instead - - "invalid-config#build". Use "build" instead $ cat tmp.log | grep "//#some-root-task" - "//#some-root-task". Use "some-root-task" instead - - "//#some-root-task". Use "some-root-task" instead $ cat tmp.log | grep "extends" - No "extends" key found - - No "extends" key found Same error even if you're running a valid task in the package. $ ${TURBO} run valid-task --filter=invalid-config > tmp.log 2>&1 [1] $ cat tmp.log | grep "Invalid turbo.json" - ERROR run failed: error preparing engine: Invalid turbo.json - Turbo error: error preparing engine: Invalid turbo.json + Error: Invalid turbo.json: $ cat tmp.log | grep "invalid-config#build" - "invalid-config#build". Use "build" instead - - "invalid-config#build". Use "build" instead $ cat tmp.log | grep "//#some-root-task" - "//#some-root-task". Use "some-root-task" instead - - "//#some-root-task". Use "some-root-task" instead $ cat tmp.log | grep "extends" - No "extends" key found - - No "extends" key found diff --git a/turborepo-tests/integration/tests/workspace-configs/missing-workspace-config-deps.t b/turborepo-tests/integration/tests/workspace-configs/missing-workspace-config-deps.t index 28c4fb26e6747..136b9186562ec 100644 --- a/turborepo-tests/integration/tests/workspace-configs/missing-workspace-config-deps.t +++ b/turborepo-tests/integration/tests/workspace-configs/missing-workspace-config-deps.t @@ -16,14 +16,14 @@ Setup \xe2\x80\xa2 Remote caching disabled (esc) $ cat tmp.log | grep "missing-workspace-config:missing-workspace-config-task-with-deps" - missing-workspace-config:missing-workspace-config-task-with-deps: cache miss, executing dd477065e764a9de + missing-workspace-config:missing-workspace-config-task-with-deps: cache miss, executing 15c1611555c41e36 missing-workspace-config:missing-workspace-config-task-with-deps: missing-workspace-config:missing-workspace-config-task-with-deps: > missing-workspace-config-task-with-deps missing-workspace-config:missing-workspace-config-task-with-deps: > echo "running missing-workspace-config-task-with-deps" > out/foo.min.txt missing-workspace-config:missing-workspace-config-task-with-deps: $ cat tmp.log | grep "missing-workspace-config:missing-workspace-config-underlying-task" - missing-workspace-config:missing-workspace-config-underlying-task: cache miss, executing d9efa81215c43afb + missing-workspace-config:missing-workspace-config-underlying-task: cache miss, executing ec0c9afcc84e1029 missing-workspace-config:missing-workspace-config-underlying-task: missing-workspace-config:missing-workspace-config-underlying-task: > missing-workspace-config-underlying-task missing-workspace-config:missing-workspace-config-underlying-task: > echo "running missing-workspace-config-underlying-task" @@ -31,7 +31,7 @@ Setup missing-workspace-config:missing-workspace-config-underlying-task: running missing-workspace-config-underlying-task $ cat tmp.log | grep "blank-pkg:missing-workspace-config-underlying-topo-task" - blank-pkg:missing-workspace-config-underlying-topo-task: cache miss, executing b4559fb480232c52 + blank-pkg:missing-workspace-config-underlying-topo-task: cache miss, executing 2d1b2897d74a6a28 blank-pkg:missing-workspace-config-underlying-topo-task: blank-pkg:missing-workspace-config-underlying-topo-task: > missing-workspace-config-underlying-topo-task blank-pkg:missing-workspace-config-underlying-topo-task: > echo "missing-workspace-config-underlying-topo-task from blank-pkg" diff --git a/turborepo-tests/integration/tests/workspace-configs/missing-workspace-config.t b/turborepo-tests/integration/tests/workspace-configs/missing-workspace-config.t index 035788bae2db8..ac48b29ae4055 100644 --- a/turborepo-tests/integration/tests/workspace-configs/missing-workspace-config.t +++ b/turborepo-tests/integration/tests/workspace-configs/missing-workspace-config.t @@ -12,7 +12,7 @@ Setup \xe2\x80\xa2 Packages in scope: missing-workspace-config (esc) \xe2\x80\xa2 Running missing-workspace-config-task in 1 packages (esc) \xe2\x80\xa2 Remote caching disabled (esc) - missing-workspace-config:missing-workspace-config-task: cache miss, executing 3b9c040c7ac66cfd + missing-workspace-config:missing-workspace-config-task: cache miss, executing 1fdbc260f9c52e23 missing-workspace-config:missing-workspace-config-task: missing-workspace-config:missing-workspace-config-task: > missing-workspace-config-task missing-workspace-config:missing-workspace-config-task: > echo "running missing-workspace-config-task" > out/foo.min.txt @@ -34,7 +34,7 @@ Setup \xe2\x80\xa2 Packages in scope: missing-workspace-config (esc) \xe2\x80\xa2 Running missing-workspace-config-task in 1 packages (esc) \xe2\x80\xa2 Remote caching disabled (esc) - missing-workspace-config:missing-workspace-config-task: cache hit, suppressing logs 3b9c040c7ac66cfd + missing-workspace-config:missing-workspace-config-task: cache hit, suppressing logs 1fdbc260f9c52e23 Tasks: 1 successful, 1 total Cached: 1 cached, 1 total @@ -46,7 +46,7 @@ Setup \xe2\x80\xa2 Packages in scope: missing-workspace-config (esc) \xe2\x80\xa2 Running missing-workspace-config-task in 1 packages (esc) \xe2\x80\xa2 Remote caching disabled (esc) - missing-workspace-config:missing-workspace-config-task: cache miss, executing 395c409c711b5ddd + missing-workspace-config:missing-workspace-config-task: cache miss, executing 8e719d7789b29b9b missing-workspace-config:missing-workspace-config-task: missing-workspace-config:missing-workspace-config-task: > missing-workspace-config-task missing-workspace-config:missing-workspace-config-task: > echo "running missing-workspace-config-task" > out/foo.min.txt @@ -63,7 +63,7 @@ Setup \xe2\x80\xa2 Packages in scope: missing-workspace-config (esc) \xe2\x80\xa2 Running missing-workspace-config-task in 1 packages (esc) \xe2\x80\xa2 Remote caching disabled (esc) - missing-workspace-config:missing-workspace-config-task: cache hit, suppressing logs 395c409c711b5ddd + missing-workspace-config:missing-workspace-config-task: cache hit, suppressing logs 8e719d7789b29b9b Tasks: 1 successful, 1 total Cached: 1 cached, 1 total @@ -74,7 +74,7 @@ Setup \xe2\x80\xa2 Packages in scope: missing-workspace-config (esc) \xe2\x80\xa2 Running missing-workspace-config-task in 1 packages (esc) \xe2\x80\xa2 Remote caching disabled (esc) - missing-workspace-config:missing-workspace-config-task: cache miss, executing fa4ab59ed5ad6d27 + missing-workspace-config:missing-workspace-config-task: cache miss, executing 354e819fd6757037 missing-workspace-config:missing-workspace-config-task: missing-workspace-config:missing-workspace-config-task: > missing-workspace-config-task missing-workspace-config:missing-workspace-config-task: > echo "running missing-workspace-config-task" > out/foo.min.txt @@ -90,7 +90,7 @@ Setup \xe2\x80\xa2 Packages in scope: missing-workspace-config (esc) \xe2\x80\xa2 Running cached-task-4 in 1 packages (esc) \xe2\x80\xa2 Remote caching disabled (esc) - missing-workspace-config:cached-task-4: cache bypass, force executing c8da5a74f0fc7fdf + missing-workspace-config:cached-task-4: cache bypass, force executing aa6cce01b130735a missing-workspace-config:cached-task-4: missing-workspace-config:cached-task-4: > cached-task-4 missing-workspace-config:cached-task-4: > echo 'cached-task-4' > out/foo.min.txt diff --git a/turborepo-tests/integration/tests/workspace-configs/omit-keys-deps.t b/turborepo-tests/integration/tests/workspace-configs/omit-keys-deps.t index 157da10f02cf8..513f0ac84c2a9 100644 --- a/turborepo-tests/integration/tests/workspace-configs/omit-keys-deps.t +++ b/turborepo-tests/integration/tests/workspace-configs/omit-keys-deps.t @@ -16,14 +16,14 @@ Setup \xe2\x80\xa2 Running omit-keys-task-with-deps in 1 packages (esc) $ cat tmp.log | grep "omit-keys:omit-keys-task-with-deps" - omit-keys:omit-keys-task-with-deps: cache miss, executing 87225ff2160987c9 + omit-keys:omit-keys-task-with-deps: cache miss, executing 1f332c26788892e8 omit-keys:omit-keys-task-with-deps: omit-keys:omit-keys-task-with-deps: > omit-keys-task-with-deps omit-keys:omit-keys-task-with-deps: > echo "running omit-keys-task-with-deps" > out/foo.min.txt omit-keys:omit-keys-task-with-deps: $ cat tmp.log | grep "omit-keys:omit-keys-underlying-task" - omit-keys:omit-keys-underlying-task: cache miss, executing 35f36d2a612e43bb + omit-keys:omit-keys-underlying-task: cache miss, executing dd15a0513f15c205 omit-keys:omit-keys-underlying-task: omit-keys:omit-keys-underlying-task: > omit-keys-underlying-task omit-keys:omit-keys-underlying-task: > echo "running omit-keys-underlying-task" @@ -31,7 +31,7 @@ Setup omit-keys:omit-keys-underlying-task: running omit-keys-underlying-task $ cat tmp.log | grep "blank-pkg:omit-keys-underlying-topo-task" - blank-pkg:omit-keys-underlying-topo-task: cache miss, executing d7764c80c8a55c88 + blank-pkg:omit-keys-underlying-topo-task: cache miss, executing 5877d2f7422d4e53 blank-pkg:omit-keys-underlying-topo-task: blank-pkg:omit-keys-underlying-topo-task: > omit-keys-underlying-topo-task blank-pkg:omit-keys-underlying-topo-task: > echo "omit-keys-underlying-topo-task from blank-pkg" diff --git a/turborepo-tests/integration/tests/workspace-configs/omit-keys.t b/turborepo-tests/integration/tests/workspace-configs/omit-keys.t index 3d30949073f75..1fc234a06bd29 100644 --- a/turborepo-tests/integration/tests/workspace-configs/omit-keys.t +++ b/turborepo-tests/integration/tests/workspace-configs/omit-keys.t @@ -15,7 +15,7 @@ Setup \xe2\x80\xa2 Packages in scope: omit-keys (esc) \xe2\x80\xa2 Running omit-keys-task in 1 packages (esc) \xe2\x80\xa2 Remote caching disabled (esc) - omit-keys:omit-keys-task: cache miss, executing b5601a9434941180 + omit-keys:omit-keys-task: cache miss, executing c3284605fe485f59 omit-keys:omit-keys-task: omit-keys:omit-keys-task: > omit-keys-task omit-keys:omit-keys-task: > echo "running omit-keys-task" > out/foo.min.txt @@ -37,7 +37,7 @@ Setup \xe2\x80\xa2 Packages in scope: omit-keys (esc) \xe2\x80\xa2 Running omit-keys-task in 1 packages (esc) \xe2\x80\xa2 Remote caching disabled (esc) - omit-keys:omit-keys-task: cache hit, suppressing logs b5601a9434941180 + omit-keys:omit-keys-task: cache hit, suppressing logs c3284605fe485f59 Tasks: 1 successful, 1 total Cached: 1 cached, 1 total @@ -49,7 +49,7 @@ Setup \xe2\x80\xa2 Packages in scope: omit-keys (esc) \xe2\x80\xa2 Running omit-keys-task in 1 packages (esc) \xe2\x80\xa2 Remote caching disabled (esc) - omit-keys:omit-keys-task: cache miss, executing d6273078707d2688 + omit-keys:omit-keys-task: cache miss, executing 8240e8a1dae6fdc7 omit-keys:omit-keys-task: omit-keys:omit-keys-task: > omit-keys-task omit-keys:omit-keys-task: > echo "running omit-keys-task" > out/foo.min.txt @@ -66,7 +66,7 @@ Setup \xe2\x80\xa2 Packages in scope: omit-keys (esc) \xe2\x80\xa2 Running omit-keys-task in 1 packages (esc) \xe2\x80\xa2 Remote caching disabled (esc) - omit-keys:omit-keys-task: cache hit, suppressing logs d6273078707d2688 + omit-keys:omit-keys-task: cache hit, suppressing logs 8240e8a1dae6fdc7 Tasks: 1 successful, 1 total Cached: 1 cached, 1 total @@ -77,7 +77,7 @@ Setup \xe2\x80\xa2 Packages in scope: omit-keys (esc) \xe2\x80\xa2 Running omit-keys-task in 1 packages (esc) \xe2\x80\xa2 Remote caching disabled (esc) - omit-keys:omit-keys-task: cache miss, executing ff83cd6411196d29 + omit-keys:omit-keys-task: cache miss, executing 4ea795337e107924 omit-keys:omit-keys-task: omit-keys:omit-keys-task: > omit-keys-task omit-keys:omit-keys-task: > echo "running omit-keys-task" > out/foo.min.txt diff --git a/turborepo-tests/integration/tests/workspace-configs/override-values-deps.t b/turborepo-tests/integration/tests/workspace-configs/override-values-deps.t index e8efd38feb658..545a4448eb3aa 100644 --- a/turborepo-tests/integration/tests/workspace-configs/override-values-deps.t +++ b/turborepo-tests/integration/tests/workspace-configs/override-values-deps.t @@ -13,7 +13,7 @@ Setup \xe2\x80\xa2 Packages in scope: override-values (esc) \xe2\x80\xa2 Running override-values-task-with-deps in 1 packages (esc) \xe2\x80\xa2 Remote caching disabled (esc) - override-values:override-values-task-with-deps: cache miss, executing 83ee0949c3d7de54 + override-values:override-values-task-with-deps: cache miss, executing 57270f0d2280c18d override-values:override-values-task-with-deps: override-values:override-values-task-with-deps: > override-values-task-with-deps override-values:override-values-task-with-deps: > echo "running override-values-task-with-deps" > out/foo.min.txt diff --git a/turborepo-tests/integration/tests/workspace-configs/override-values.t b/turborepo-tests/integration/tests/workspace-configs/override-values.t index a58ab5a3b2ef6..cd03367b08db6 100644 --- a/turborepo-tests/integration/tests/workspace-configs/override-values.t +++ b/turborepo-tests/integration/tests/workspace-configs/override-values.t @@ -12,7 +12,7 @@ Setup \xe2\x80\xa2 Packages in scope: override-values (esc) \xe2\x80\xa2 Running override-values-task in 1 packages (esc) \xe2\x80\xa2 Remote caching disabled (esc) - override-values:override-values-task: cache miss, executing 676bf15624566937 + override-values:override-values-task: cache miss, executing 32366d68970bb985 override-values:override-values-task: override-values:override-values-task: > override-values-task override-values:override-values-task: > echo "running override-values-task" > lib/bar.min.txt @@ -34,7 +34,7 @@ Setup \xe2\x80\xa2 Packages in scope: override-values (esc) \xe2\x80\xa2 Running override-values-task in 1 packages (esc) \xe2\x80\xa2 Remote caching disabled (esc) - override-values:override-values-task: cache hit, replaying logs 676bf15624566937 + override-values:override-values-task: cache hit, replaying logs 32366d68970bb985 override-values:override-values-task: override-values:override-values-task: > override-values-task override-values:override-values-task: > echo "running override-values-task" > lib/bar.min.txt @@ -50,7 +50,7 @@ Setup \xe2\x80\xa2 Packages in scope: override-values (esc) \xe2\x80\xa2 Running override-values-task in 1 packages (esc) \xe2\x80\xa2 Remote caching disabled (esc) - override-values:override-values-task: cache miss, executing 04f174d88e33b365 + override-values:override-values-task: cache miss, executing 43b2bcc57fcd9977 override-values:override-values-task: override-values:override-values-task: > override-values-task override-values:override-values-task: > echo "running override-values-task" > lib/bar.min.txt @@ -66,7 +66,7 @@ Setup \xe2\x80\xa2 Packages in scope: override-values (esc) \xe2\x80\xa2 Running override-values-task in 1 packages (esc) \xe2\x80\xa2 Remote caching disabled (esc) - override-values:override-values-task: cache hit, replaying logs 04f174d88e33b365 + override-values:override-values-task: cache hit, replaying logs 43b2bcc57fcd9977 override-values:override-values-task: override-values:override-values-task: > override-values-task override-values:override-values-task: > echo "running override-values-task" > lib/bar.min.txt @@ -81,7 +81,7 @@ Setup \xe2\x80\xa2 Packages in scope: override-values (esc) \xe2\x80\xa2 Running override-values-task in 1 packages (esc) \xe2\x80\xa2 Remote caching disabled (esc) - override-values:override-values-task: cache miss, executing bb2616d0a2d6716c + override-values:override-values-task: cache miss, executing 61eed6557e9e4196 override-values:override-values-task: override-values:override-values-task: > override-values-task override-values:override-values-task: > echo "running override-values-task" > lib/bar.min.txt @@ -96,7 +96,7 @@ Setup \xe2\x80\xa2 Packages in scope: override-values (esc) \xe2\x80\xa2 Running override-values-task in 1 packages (esc) \xe2\x80\xa2 Remote caching disabled (esc) - override-values:override-values-task: cache hit, replaying logs bb2616d0a2d6716c + override-values:override-values-task: cache hit, replaying logs 61eed6557e9e4196 override-values:override-values-task: override-values:override-values-task: > override-values-task override-values:override-values-task: > echo "running override-values-task" > lib/bar.min.txt diff --git a/turborepo-tests/integration/tests/workspace-configs/persistent.t b/turborepo-tests/integration/tests/workspace-configs/persistent.t index 61ca182bb0139..0ed40a3b1ffce 100644 --- a/turborepo-tests/integration/tests/workspace-configs/persistent.t +++ b/turborepo-tests/integration/tests/workspace-configs/persistent.t @@ -23,13 +23,13 @@ This test covers: \xe2\x80\xa2 Packages in scope: persistent (esc) \xe2\x80\xa2 Running persistent-task-2-parent in 1 packages (esc) \xe2\x80\xa2 Remote caching disabled (esc) - persistent:persistent-task-2: cache miss, executing a0b42f53924052be + persistent:persistent-task-2: cache miss, executing 41068affe1358537 persistent:persistent-task-2: persistent:persistent-task-2: > persistent-task-2 persistent:persistent-task-2: > echo 'persistent-task-2' persistent:persistent-task-2: persistent:persistent-task-2: persistent-task-2 - persistent:persistent-task-2-parent: cache miss, executing 42eb98953cca04a6 + persistent:persistent-task-2-parent: cache miss, executing 1a538bdf0688d0b0 persistent:persistent-task-2-parent: persistent:persistent-task-2-parent: > persistent-task-2-parent persistent:persistent-task-2-parent: > echo 'persistent-task-2-parent'