Vaya, se resolvió el problema aparentemente pero me sigue dando problemas través la shell: <pre> In [59]: Mymodel.objects.all() Out[59]: --------------------------------------------------------------------------- UnicodeDecodeError Traceback (most recent call last)
/home/user/myproject/<ipython console> in <module>() /var/lib/python-support/python2.5/IPython/Prompts.pyc in __call__(self, arg) 549 550 # and now call a possibly user-defined print mechanism --> 551 manipulated_val = self.display(arg) 552 553 # user display hooks can change the variable to be stored in /var/lib/python-support/python2.5/IPython/Prompts.pyc in _display(self, arg) 575 return IPython.generics.result_display(arg) 576 except TryNext: --> 577 return self.shell.hooks.result_display(arg) 578 579 # Assign the default display method: /var/lib/python-support/python2.5/IPython/hooks.pyc in __call__(self, *args, **kw) 133 #print "prio",prio,"cmd",cmd #dbg 134 try: --> 135 ret = cmd(*args, **kw) 136 return ret 137 except ipapi.TryNext, exc: /var/lib/python-support/python2.5/IPython/hooks.pyc in result_display(self, arg) 163 164 if self.rc.pprint: --> 165 out = pformat(arg) 166 if '\n' in out: 167 # So that multi-line strings line up with the left column of /usr/lib/python2.5/pprint.pyc in pformat(self, object) 109 def pformat(self, object): 110 sio = _StringIO() --> 111 self._format(object, sio, 0, 0, {}, 0) 112 return sio.getvalue() 113 /usr/lib/python2.5/pprint.pyc in _format(self, object, stream, indent, allowance, context, level) 127 self._readable = False 128 return --> 129 rep = self._repr(object, context, level - 1) 130 typ = _type(object) 131 sepLines = _len(rep) > (self._width - 1 - indent - allowance) /usr/lib/python2.5/pprint.pyc in _repr(self, object, context, level) 193 def _repr(self, object, context, level): 194 repr, readable, recursive = self.format(object, context.copy(), --> 195 self._depth, level) 196 if not readable: 197 self._readable = False /usr/lib/python2.5/pprint.pyc in format(self, object, context, maxlevels, level) 205 and whether the object represents a recursive construct. 206 """ --> 207 return _safe_repr(object, context, maxlevels, level) 208 209 /usr/lib/python2.5/pprint.pyc in _safe_repr(object, context, maxlevels, level) 290 return format % _commajoin(components), readable, recursive 291 --> 292 rep = repr(object) 293 return rep, (rep and not rep.startswith('<')), False 294 /home/user/myproject/myapp/django/db/models/query.pyc in __repr__(self) 139 140 def __repr__(self): --> 141 return repr(list(self)) 142 143 def __len__(self): /home/user/myproject/myapp/django/db/models/base.pyc in __repr__(self) 242 243 def __repr__(self): --> 244 return smart_str(u'<%s: %s>' % (self.__class__.__name__, unicode(self).encode('utf-8'))) 245 246 def __str__(self): UnicodeDecodeError: 'ascii' codec can't decode byte 0xc3 in position 23: ordinal not in range(128) </pre> Y lo mismo cuando trato de ejecutar en una función: <pre> model = get_model(app_label, model_name) queryset = model.objects.all() fields = queryset.model._meta.admin.list_display </pre> Django me devuelve una página de error: <pre> �� Local vars Variable Value app_label 'myapp' model <class 'myproject.myapp.models.Mymodel'> model_name u'mymodel' queryset Error in formatting: 'ascii' codec can't decode byte 0xc3 in position 23: ordinal not in range(128) </pre> On Aug 21, 5:20 pm, Jeff Anderson <[EMAIL PROTECTED]> wrote: > anonymous wrote: > > > Sin DATABASE_OPTIONS se resuelve el problema en mysql!! > > > Muchas Gracias! > > De nada. > > Como dijo Karen, casi no necesita DATABASE_OPTIONS en settings.py. > Cuando se usa DATABASE_OPTIONS, solo hay que specificar el tipo del > database engine y no mas. Es posible que hay otros casos que requieren > otron opciones, pero nunca he visto un projecto que lo usa. > > Jeff Anderson > > signature.asc > < 1KViewDownload --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-users@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~----------~----~----~----~------~----~------~--~---