【问题标题】:gcloud components update crashes when updating to 224.0.0更新到 224.0.0 时 gcloud 组件更新崩溃
【发布时间】:2019-04-12 06:25:30
【问题描述】:

运行“gcloud components update”或“gcloud components list”时,它会崩溃并显示错误消息:TypeError: unsupported operand type(s) for +=: 'int' and 'NoneType'

如何解决问题?

【问题讨论】:

    标签: gcloud


    【解决方案1】:

    如果您看到此错误,很可能是您安装了container-builder-local 组件。崩溃是因为该组件在版本 224.0.0 中被删除并替换为cloud-build-local

    所以解决方法是:

    1. 删除容器生成器本地:gcloud components remove container-builder-local

    2. 更新:gcloud components update

    3. 安装云构建本地:gcloud components install cloud-build-local

    【讨论】:

    • 这救了我!谢谢!
    • 旧版本210.0.0也会发生这种情况。
    【解决方案2】:

    我目前正在使用 gcloud v222.0.0 并遇到错误: ERROR: gcloud crashed (TypeError): unsupported operand type(s) for +=: 'int' and 'NoneType' 尝试更新组件时。

    我可以确认删除 container-build-local 并更新到 cloud-build-local 可以修复此错误。

    Installing components from version: 224.0.0
    
    ┌──────────────────────────────────────────────────────┐
    │         These components will be installed.          │
    ├──────────────────────────────────┬─────────┬─────────┤
    │               Name               │ Version │   Size  │
    ├──────────────────────────────────┼─────────┼─────────┤
    │ Google Cloud Build Local Builder │   0.4.2 │ 5.9 MiB │
    │ Google Cloud Build Local Builder │         │         │
    └──────────────────────────────────┴─────────┴─────────┘
    

    我没有意识到这一重大变化

    【讨论】:

      猜你喜欢
      • 2015-03-23
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2018-10-25
      • 2014-07-31
      • 1970-01-01
      • 2020-08-12
      相关资源
      最近更新 更多