首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >升级dotcloud cli时出现问题

升级dotcloud cli时出现问题
EN

Stack Overflow用户
提问于 2012-11-18 14:31:05
回答 2查看 381关注 0票数 0

按照这里的说明操作:http://docs.dotcloud.com/0.9/guides/migration/

当我运行sudo pip install -U dotcloud

代码语言:javascript
复制
Downloading/unpacking dotcloud
  Downloading dotcloud-0.9.2.tar.gz
  Running setup.py egg_info for package dotcloud
Downloading/unpacking argparse (from dotcloud)
  Downloading argparse-1.2.1.tar.gz (69Kb): 69Kb downloaded
  Running setup.py egg_info for package argparse
    warning: no previously-included files matching '*.pyc' found anywhere in distribution
    warning: no previously-included files matching '*.pyo' found anywhere in distribution
    warning: no previously-included files matching '*.orig' found anywhere in distribution
    warning: no previously-included files matching '*.rej' found anywhere in distribution
    no previously-included directories found matching 'doc/_build'
    no previously-included directories found matching 'env24'
    no previously-included directories found matching 'env25'
    no previously-included directories found matching 'env26'
    no previously-included directories found matching 'env27'
Downloading/unpacking requests==0.14.1 (from dotcloud)
  Downloading requests-0.14.1.tar.gz (523Kb): 523Kb downloaded
  Running setup.py egg_info for package requests
    warning: no files found matching 'tests/*.'
Downloading/unpacking colorama (from dotcloud)
  Downloading colorama-0.2.4.tar.gz
  Running setup.py egg_info for package colorama
Installing collected packages: dotcloud, argparse, requests, colorama
  Running setup.py install for dotcloud
    changing mode of build/scripts-2.6/dotcloud from 644 to 755
    changing mode of /usr/local/bin/dotcloud to 755
  Found existing installation: argparse 1.2.1
    Uninstalling argparse:
      Successfully uninstalled argparse
  Running setup.py install for argparse
    warning: no previously-included files matching '*.pyc' found anywhere in distribution
    warning: no previously-included files matching '*.pyo' found anywhere in distribution
    warning: no previously-included files matching '*.orig' found anywhere in distribution
    warning: no previously-included files matching '*.rej' found anywhere in distribution
    no previously-included directories found matching 'doc/_build'
    no previously-included directories found matching 'env24'
    no previously-included directories found matching 'env25'
    no previously-included directories found matching 'env26'
    no previously-included directories found matching 'env27'
  Found existing installation: requests 0.14.1
    Uninstalling requests:
      Successfully uninstalled requests
  Running setup.py install for requests
    warning: no files found matching 'tests/*.'
  Found existing installation: colorama 0.2.4
    Uninstalling colorama:
      Successfully uninstalled colorama
  Running setup.py install for colorama
Successfully installed dotcloud argparse requests colorama
Cleaning up...

当我运行dotcloud setup

代码语言:javascript
复制
Traceback (most recent call last):
  File "/usr/local/bin/dotcloud", line 16, in <module>
    cli = CLI(endpoint=url, debug=debug, username=username)
  File "/Library/Python/2.6/site-packages/dotcloud/ui/cli.py", line 42, in __init__
    user_agent=self._build_useragent_string(),
  File "/Library/Python/2.6/site-packages/dotcloud/ui/cli.py", line 72, in     _build_useragent_string
    (langcode, encoding) = locale.getdefaultlocale()
  File "/System/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/locale.py", line 459, in getdefaultlocale
    return _parse_localename(localename)
  File "/System/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/locale.py", line 391, in _parse_localename
    raise ValueError, 'unknown locale: %s' % localename
ValueError: unknown locale: UTF-8

感谢任何人的帮助。

EN

回答 2

Stack Overflow用户

回答已采纳

发布于 2012-11-18 20:49:10

这要么是区域设置问题,要么是权限问题。

您可能没有默认的语言环境设置,或者它无法在需要时正确加载语言环境。

而不是复制所有的信息,你应该看看这个问题的答案,它可能会有所帮助。

python locale strange error. what's going on here exactly?

票数 0
EN

Stack Overflow用户

发布于 2012-11-18 23:13:45

cli似乎正在访问locale._parse_localname方法,并且遇到了ValueError,因为它找不到UTF-8值的区域设置。

下面提供的这篇博客文章的链接表明,如果您修改您的~/.bash_profile (或某些系统上的~/.profile )并导出值,它将解决您看到的问题。如果您选择修改您的文件,请确保首先备份它们(以防万一!)。

http://patrick.arminio.info/blog/2012/02/fix-valueerror-unknown-locale-utf8/

票数 0
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/13438020

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档