azure - 更新 azure-sdk-for-go 库依赖项
问题描述
执行此任务的最佳做法是什么?
到目前为止我尝试了什么,只需运行dep ensure -update github.com/Azure/azure-sdk-for-go
引发以下错误的命令:
Warning: the following project(s) have [[constraint]] stanzas in Gopkg.toml:
✗ github.com/gravitational/trace
.....
dep ensure
dep -update
给了我与命令类似的错误。dep check
给出以下输出:
# Gopkg.lock is out of sync:
github.com/Azure/azure-sdk-for-go/arm/compute: imported or required, but missing from Gopkg.lock's input-imports
.....
和
# vendor is out of sync:
cloud.google.com/go: no digest in Gopkg.lock to compare against hash of vendored tree
github.com/Azure/azure-sdk-for-go: no digest in Gopkg.lock to compare against hash of vendored tree
....
这是一个相当大的项目。我应该手动将代码中的所有现有依赖项删除到旧的import azure-sdk-for-go
吗?或者应该deb
能够执行这个任务?我尝试了各种技巧来使其正常工作,例如手动修改Gopk.lock
文件,删除azure-sdk-for-go
文件夹中的vendor
文件夹,但到目前为止我没有运气。对此的任何帮助将不胜感激。
解决方案
看起来您是从一个相当旧的版本更新的,因为github.com/Azure/azure-sdk-for-go/arm/compute
在此 SDK 仍处于预览阶段时,已在大约一年前被弃用和删除。
要继续前进,您应该将计算路径更新为github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2018-10-01/compute
. 从那时起,还将采用其他几项重大更改。
推荐阅读
- interface - 在 F# 中,如何将接口添加到部分类(来自另一个项目)
- javascript - 如何在 Jest 中测试内部商店更新?
- html - 如何用xml和xsl显示img
- oracle-sqldeveloper - sql developer上的连接按钮不见了。怎么了?
- python - 如何将所有元素从 xml 检索到 pandas DataFrame?PYTHON
- javascript - 即使我用数据填充了状态,Redux 状态也会显示 null[Object object]
- powerbi - 给定条件发生的最后日期 - Power BI
- apache-spark - 如何将文件传输到火花执行器
- swift - [Swift]如何使用 ReadLine 初始化一个期望 String 的类?
- vue.js - 如何在 vuetify v-calendar 中向事件添加信息?