Status: New
Owner: ----

New issue 187 by chinacang: ulipad下执行配置django数据库时出错
http://code.google.com/p/ulipad/issues/detail?id=187

What steps will reproduce the problem?
1. 安装好django环境,建立一个项目mysite
2. 在setting.py内设置好db的配置,用的是sqlite3数据库
3. 在UliPad中对manage.py设置好参数syncdb,然后执行,执行过程中创建 superuser出错

What is the expected output? What do you see instead?
"/usr/bin/python" -u "/home/barney/mysite/manage.py" syncdb
Creating table auth_permission
Creating table auth_group
Creating table auth_user
Creating table auth_message
Creating table django_content_type
Creating table django_session
Creating table django_site
Creating table blog_blogpost

You just installed Django's auth system, which means you don't have any
superusers defined.
Would you like to create one now? (yes/no): yes
Username (Leave blank to use 'barney'): cc
E-mail address: [email protected]
Traceback (most recent call last):
  File "/home/barney/mysite/manage.py", line 11, in <module>
    execute_manager(settings)
  File
"/usr/lib/python2.5/site-packages/django/core/management/__init__.py", line
340, in execute_manager
    utility.execute()
  File
"/usr/lib/python2.5/site-packages/django/core/management/__init__.py", line
295, in execute
    self.fetch_command(subcommand).run_from_argv(self.argv)
  File "/usr/lib/python2.5/site-packages/django/core/management/base.py",
line 192, in run_from_argv
    self.execute(*args, **options.__dict__)
  File "/usr/lib/python2.5/site-packages/django/core/management/base.py",
line 219, in execute
    output = self.handle(*args, **options)
  File "/usr/lib/python2.5/site-packages/django/core/management/base.py",
line 348, in handle
    return self.handle_noargs(**options)
  File
"/usr/lib/python2.5/site-packages/django/core/management/commands/syncdb.py",
line 101, in handle_noargs
    emit_post_sync_signal(created_models, verbosity, interactive)
  File "/usr/lib/python2.5/site-packages/django/core/management/sql.py",
line 205, in emit_post_sync_signal
    interactive=interactive)
  File "/usr/lib/python2.5/site-packages/django/dispatch/dispatcher.py",
line 148, in send
    response = receiver(signal=self, sender=sender, **named)
  File
"/usr/lib/python2.5/site-packages/django/contrib/auth/management/__init__.py",
line 44, in create_superuser
    call_command("createsuperuser", interactive=True)
  File
"/usr/lib/python2.5/site-packages/django/core/management/__init__.py", line
158, in call_command
    return klass.execute(*args, **options)
  File "/usr/lib/python2.5/site-packages/django/core/management/base.py",
line 219, in execute
    output = self.handle(*args, **options)
  File
"/usr/lib/python2.5/site-packages/django/contrib/auth/management/commands/createsuperuser.py",
line 118, in handle
    password = getpass.getpass()
  File "/usr/lib/python2.5/getpass.py", line 32, in unix_getpass
    old = termios.tcgetattr(fd)     # a copy to save
termios.error: (22, 'Invalid argument')

正常情况应该是:
bar...@ubuntu-20090616220833:~/mysite$ python manage.py syncdb
Creating table auth_permission
Creating table auth_group
Creating table auth_user
Creating table auth_message
Creating table django_content_type
Creating table django_session
Creating table django_site
Creating table blog_blogpost

You just installed Django's auth system, which means you don't have any
superusers defined.
Would you like to create one now? (yes/no): yes
Username (Leave blank to use 'barney'):
E-mail address: [email protected]
Password:
Password (again):
Superuser created successfully.
Installing index for auth.Permission model
Installing index for auth.Message model

What version of the product are you using? On what operating system?
UliPad3.9
On Ubuntu8.10

Please provide any additional information below.
根据《Django Web开发指南》(第2章), 中的步骤部署django数据库sqlite3时,在
UliPad3.9下执行“python manage.py syncdb”时调试出现这个错误。然后换到终端下
没有出现错误,能正常执行下去。


--
You received this message because you are listed in the owner
or CC fields of this issue, or because you starred this issue.
You may adjust your issue notification preferences at:
http://code.google.com/hosting/settings

Reply via email to