亚洲在线久爱草,狠狠天天香蕉网,天天搞日日干久草,伊人亚洲日本欧美

為了賬號安全,請及時綁定郵箱和手機立即綁定
已解決430363個問題,去搜搜看,總會有你想問的

如何在 azure pipeline 中使用 Go Beta/RC 版本

如何在 azure pipeline 中使用 Go Beta/RC 版本

Go
慕斯709654 2022-09-12 20:46:02
我想在 Azure 管道中使用 Go 的測試版或發布版,但任務“Go 工具安裝程序”不適用于“1.17rc1”等版本。管道$(go_version) = 1.17rc1steps:  - task: GoTool@0    displayName: Install Go tools in version $(go_version)    inputs:      version: $(go_version)輸出2021-07-15T08:01:13.5566938Z ##[section]Starting: Install Go tools in version 1.17rc12021-07-15T08:01:13.5573377Z ==============================================================================2021-07-15T08:01:13.5573650Z Task         : Go tool installer2021-07-15T08:01:13.5574064Z Description  : Find in cache or download a specific version of Go and add it to the PATH2021-07-15T08:01:13.5574305Z Version      : 0.180.02021-07-15T08:01:13.5574495Z Author       : Microsoft Corporation2021-07-15T08:01:13.5574776Z Help         : https://docs.microsoft.com/azure/devops/pipelines/tasks/tool/go-tool2021-07-15T08:01:13.5575073Z ==============================================================================2021-07-15T08:01:13.8414712Z Downloading: https://storage.googleapis.com/golang/go1.17rc1.linux-amd64.tar.gz2021-07-15T08:01:16.3008064Z Extracting archive2021-07-15T08:01:16.3027619Z [command]/usr/bin/tar xC /home/vsts/work/_temp/50a79994-bdb5-417d-8374-cd9746166c5f -f /home/vsts/work/_temp/d2be4a68-029c-4393-8492-5b804e41857e2021-07-15T08:01:19.0933870Z Caching tool: go null x642021-07-15T08:01:19.1004014Z ##[error]TypeError: Cannot read property 'trim' of null2021-07-15T08:01:19.1090132Z ##[section]Finishing: Install Go tools in version 1.17rc1
查看完整描述

1 回答

?
慕慕森

TA貢獻1856條經驗 獲得超17個贊

這看起來像是任務本身的問題。它拋出這里:


async function run() {

    try {

        let version = tl.getInput('version', true).trim();

        await getGo(version);

        telemetry.emitTelemetry('TaskHub', 'GoToolV0', { version });

    }

    catch (error) {

        tl.setResult(tl.TaskResult.Failed, error);

    }

}

這有點奇怪,因為我在這里沒有看到任何邏輯阻止放在那里。我在 GitHub 上為此創建并發布1.17rc1


查看完整回答
反對 回復 2022-09-12
  • 1 回答
  • 0 關注
  • 127 瀏覽
慕課專欄
更多

添加回答

舉報

0/150
提交
取消
微信客服

購課補貼
聯系客服咨詢優惠詳情

幫助反饋 APP下載

慕課網APP
您的移動學習伙伴

公眾號

掃描二維碼
關注慕課網微信公眾號