The setup-argo action requires Go, but it doesn't document that requirement.
Notice that because the way this action is constructed, this is not a hard requirement. Go is only used when the cache doesn't have the necessary file (it has expired, you are running it for the first time, the Argo version has changed).
Notice that the companion action, trigger-argo-workflow, does use setup-go to avoid requiring it be present in the system. This is a strange setup: setup-argo assumes Go is present and blindly uses it, trigger-argo-workflow assumes it's not present and downloads it from the Internet. You could argue that starting with Go 1.21 this is not needed, as Go itself will download a newer toolchain if necessary.
Notice also that because setup-argo is only using Go to map the runner's OS and architecture to Go's GOOS and GOARCH variables (in order to download the right Argo binary), it doesn't need a go.mod file. For this reason, using setup-go here would not work: with setup-go, you must either pass the Go version you want to use or specify the path to go.mod (to extract the Go version from it). If the version is not provided and go.mod doesn't exist, setup-go fails. trigger-argo-workflow does use the Go compiler and it has a go.mod file, this is why it can use setup-go.
The setup-argo action requires Go, but it doesn't document that requirement.
Notice that because the way this action is constructed, this is not a hard requirement. Go is only used when the cache doesn't have the necessary file (it has expired, you are running it for the first time, the Argo version has changed).
Notice that the companion action, trigger-argo-workflow, does use setup-go to avoid requiring it be present in the system. This is a strange setup:
setup-argoassumes Go is present and blindly uses it,trigger-argo-workflowassumes it's not present and downloads it from the Internet. You could argue that starting with Go 1.21 this is not needed, as Go itself will download a newer toolchain if necessary.Notice also that because
setup-argois only using Go to map the runner's OS and architecture to Go's GOOS and GOARCH variables (in order to download the right Argo binary), it doesn't need ago.modfile. For this reason, usingsetup-gohere would not work: withsetup-go, you must either pass the Go version you want to use or specify the path togo.mod(to extract the Go version from it). If the version is not provided andgo.moddoesn't exist,setup-gofails.trigger-argo-workflowdoes use the Go compiler and it has a go.mod file, this is why it can usesetup-go.