Don't like ads? PRO users don't see any ads ;-)
Guest

Untitled

By: a guest on May 20th, 2012  |  syntax: None  |  size: 3.19 KB  |  hits: 22  |  expires: Never
download  |  raw  |  embed  |  report abuse  |  print
Text below is selected. Please press Ctrl+C to copy to your clipboard. (⌘+C on Mac)
  1. Django non-rel createsuperuser fails due to non-ascii characters
  2. Traceback (most recent call last):
  3. File "manage.py", line 11, in <module>
  4. execute_manager(settings)
  5. File "C:empeericpickadealdjangocoremanagement__init__.py", line 438, in execute_manager
  6. utility.execute()
  7. File "C:empeericpickadealdjangocoremanagement__init__.py", line 379, in execute
  8. self.fetch_command(subcommand).run_from_argv(self.argv)
  9. File "C:empeericpickadealdjangocoremanagementbase.py", line 191, in run_from_argv
  10. self.execute(*args, **options.__dict__)
  11. File "C:empeericpickadealdjangocoremanagementbase.py", line 220, in execute
  12. output = self.handle(*args, **options)
  13. File "C:empeericpickadealdjangocontribauthmanagementcommandscreatesuperuser.py", line 72, in handle
  14. User.objects.get(username=default_username)
  15. File "C:empeericpickadealdjangodbmodelsmanager.py", line 132, in get
  16. return self.get_query_set().get(*args, **kwargs)
  17. File "C:empeericpickadealdjangodbmodelsquery.py", line 346, in get
  18. num = len(clone)
  19. File "C:empeericpickadealdjangodbmodelsquery.py", line 82, in __len__
  20. self._result_cache = list(self.iterator())
  21. File "C:empeericpickadealdjangodbmodelsquery.py", line 275, in iterator
  22. for row in compiler.results_iter():
  23. File "C:empeericpickadealdjangotoolboxdbbasecompiler.py", line 229, in results_iter
  24. for entity in self.build_query(fields).fetch(low_mark, high_mark):
  25. File "C:empeericpickadealdjangotoolboxdbbasecompiler.py", line 289, in build_query
  26. query.add_filters(self.query.where)
  27. File "C:empeericpickadealdjangotoolboxdbbasecompiler.py", line 74, in add_filters
  28. self.add_filters(child)
  29. File "C:empeericpickadealdjangotoolboxdbbasecompiler.py", line 78, in add_filters
  30. self.add_filter(column, lookup_type, self._negated, db_type, value)
  31. File "C:empeericpickadealdjangoappenginedbcompiler.py", line 61, in _func
  32. return func(*args, **kwargs)
  33. File "C:empeericpickadealdjangoappenginedbcompiler.py", line 271, in add_filter
  34. self._add_filter(column, op, db_type, value)
  35. File "C:empeericpickadealdjangoappenginedbcompiler.py", line 279, in _add_filter
  36. value = self.convert_value_for_db(db_type, value)
  37. File "C:empeericpickadealdjangotoolboxdbbasecompiler.py", line 209, in convert_value_for_db
  38. return self.compiler.convert_value_for_db(db_type, value)
  39. File "C:empeericpickadealdjangoappenginedbcompiler.py", line 445, in convert_value_for_db
  40. value = value.decode('utf-8') if isinstance(value, str) else value
  41. File "C:hpbinPythonlibencodingsutf_8.py", line 16, in decode
  42. return codecs.utf_8_decode(input, errors, True)
  43. UnicodeDecodeError: 'utf8' codec can't decode bytes in position 0-4: unsupported Unicode code range
  44. Exception exceptions.AttributeError: "'NoneType' object has no attribute 'mkstemp'" in <bound method DatastoreFileStub.__del__ of <google.appengine.api.datasto
  45. e_file_stub.DatastoreFileStub object at 0x02277890>> ignored
  46.        
  47. # Try to determine the current system user's username to use as a default.
  48.     try:
  49.         default_username = getpass.getuser().replace(' ', '').lower()
  50.     except (ImportError, KeyError):
  51.         # KeyError will be raised by os.getpwuid() (called by getuser())
  52.         # if there is no corresponding entry in the /etc/passwd file
  53.         # (a very restricted chroot environment, for example).
  54.         default_username = ''