I think the GitHub actions actually uses the Automation API to execute commands rather than invoking the CLI (although it does also install that too). I think the CLI version is therefore not able to be specified and probably wouldn't fix an issue - as the automation API is part of the
@pulumi/pulumi
package