Closed GoogleCodeExporter closed 8 years ago
So if I remove the line
"revision": 20151118121533,
from the config.json file
Things appear to work again. How important is that revision key?
$ gcloud
Usage: gcloud [optional flags] <group | command>
group may be auth | components | compute | config | container |
deployment-manager | dns | preview | source | sql |
topic
command may be docker | feedback | help | info | init | version
The *gcloud* CLI manages authentication, local configuration, developer
workflow, and interactions with the Google Cloud Platform APIs.
....
Original comment by vsi...@gmail.com
on 19 Nov 2015 at 9:47
Same error on ubuntu vivid, this time it was an upgrade from 0.86 to 0.87.1
The following packages will be upgraded:
google-cloud-sdk
1 upgraded, 0 newly installed, 0 to remove and 58 not upgraded.
Need to get 4,360 kB of archives.
After this operation, 88.1 kB of additional disk space will be used.
Get:1 http://packages.cloud.google.com/apt/ cloud-sdk-vivid/main
google-cloud-sdk all 0.9.87.1-20151118121533-0 [4,360 kB]
Fetched 4,360 kB in 0s (6,065 kB/s)
(Reading database ... 299808 files and directories currently installed.)
Preparing to unpack .../google-cloud-sdk_0.9.87.1-20151118121533-0_all.deb ...
Unpacking google-cloud-sdk (0.9.87.1-20151118121533-0) over
(0.9.86-20151106084643-0) ...
Processing triggers for man-db (2.7.0.2-5) ...
Setting up google-cloud-sdk (0.9.87.1-20151118121533-0) ...
Traceback (most recent call last):
File "/usr/bin/../lib/google-cloud-sdk/./lib/googlecloudsdk/gcloud/gcloud.py", line 86, in <module>
from googlecloudsdk.calliope import base
File "/usr/bin/../lib/google-cloud-sdk/./lib/googlecloudsdk/calliope/base.py", line 8, in <module>
from googlecloudsdk.calliope import usage_text
File "/usr/bin/../lib/google-cloud-sdk/./lib/googlecloudsdk/calliope/usage_text.py", line 12, in <module>
from googlecloudsdk.calliope import arg_parsers
File "/usr/bin/../lib/google-cloud-sdk/./lib/googlecloudsdk/calliope/arg_parsers.py", line 43, in <module>
from googlecloudsdk.core import log
File "/usr/bin/../lib/google-cloud-sdk/./lib/googlecloudsdk/core/log.py", line 12, in <module>
from googlecloudsdk.core import properties
File "/usr/bin/../lib/google-cloud-sdk/./lib/googlecloudsdk/core/properties.py", line 11, in <module>
from googlecloudsdk.core import exceptions
File "/usr/bin/../lib/google-cloud-sdk/./lib/googlecloudsdk/core/config.py", line 307, in <module>
File "/usr/bin/../lib/google-cloud-sdk/./lib/googlecloudsdk/core/config.py", line 279, in Load
directory name so that different release channels can have separate
TypeError: __init__() got an unexpected keyword argument 'revision'
Original comment by vsi...@gmail.com
on 19 Nov 2015 at 10:04
The revision key seems important. Further gcloud usage crashes without it.
You cannot perform this action because this Cloud SDK installation is
managed by an external package manager. If you would like to get the
latest version, please see our main download page at:
https://developers.google.com/cloud/sdk/
ERROR: (gcloud.components.update) The component manager is disabled for this
installation
You cannot perform this action because this Cloud SDK installation is
managed by an external package manager. If you would like to get the
latest version, please see our main download page at:
https://developers.google.com/cloud/sdk/
ERROR: (gcloud.components.update) The component manager is disabled for this
installation
You cannot perform this action because this Cloud SDK installation is
managed by an external package manager. If you would like to get the
latest version, please see our main download page at:
https://developers.google.com/cloud/sdk/
ERROR: (gcloud.components.update) The component manager is disabled for this
installation
ERROR: gcloud crashed (TypeError): UpdateCheck() takes exactly 1 argument (0
given)
If you would like to report this issue, please run the following command:
gcloud feedback
Original comment by vsi...@gmail.com
on 19 Nov 2015 at 11:35
I am completely unable to reproduce this bug. I created a vivid compute
instance, manually installed google-cloud-sdk_0.9.86-20151106084643-0_all.deb
and then followed the debian/ubuntu instructions on
https://cloud.google.com/sdk/?hl=en#debubu.
Can you give instructions on how to reproduce from a clean instance?
Original comment by stephe...@google.com
on 20 Nov 2015 at 6:46
[deleted comment]
Original comment by stephe...@google.com
on 20 Nov 2015 at 6:48
How about a Dockerfile?
Starting with trusty, I "inoculate" the system with 0.9.86 first and even
remove it before continuing. Since 0.9.86 is not available via apt anymore, I
install it from a deb package.
Then I install google sdk via apt as I normally would. Running gcloud doesn't
work after this.
Then I remove and install gcloud again via apt-get. Running gcloud doesn't work
after this.
If I just straight install the latest gcloud-sdk via apt, then everything works
as usual. Something about having 0.9.86 on the system first (which are all my
machines) seems to help in causing what I'm seeing.
Just do "docker build ." with my attached Dockerfile
Original comment by vsi...@gmail.com
on 20 Nov 2015 at 7:16
Attachments:
Thanks, I can reproduce with the docker file.
Original comment by stephe...@google.com
on 20 Nov 2015 at 7:46
That dockerfile was extremely helpful. The bug only manifests when you run as
root which is something I don't normally do.
Short answer:
sudo rm -rf /usr/lib/google-cloud-sdk
sudo apt-get install --reinstall google-cloud-sdk
Long answer:
We are not cleaning up pyc files which are created when you run as root. We
also normalize all timestamps to 1980 as part of our build which prevents
python from noticing the files changed. We likely should be generating these on
install anyways since it would decrease gcloud load times.
Original comment by stephe...@google.com
on 20 Nov 2015 at 9:37
Original comment by stephe...@google.com
on 20 Nov 2015 at 9:40
I just published a new debian package that retroactively fixes the problem and
prevents it from happening in the future.
As a happy accident, you should also see a major speedup in gcloud load times
since it is precompiled.
Thanks for the bug report!
Original comment by stephe...@google.com
on 23 Nov 2015 at 4:36
Thanks for the quick turnaround! Looks very good!
Original comment by vsi...@gmail.com
on 24 Nov 2015 at 2:49
Original issue reported on code.google.com by
vsi...@gmail.com
on 19 Nov 2015 at 9:07